Eclipse在运行调试器时破坏了带有空格字符的程序参数



我有一个程序需要七个参数。问题是第五个参数有空(空格)字符。所以我把它放在双引号里,程序就运行了。

问题:

当我尝试在Eclipse中使用调试器时,系统会放\"而不是"。结果是第五个参数被破坏,我无法使用调试器…

以下是我在论点列表中的内容

168815 blabla/ product_group_and_eshop_global_id blaee/test/test "<unique_string>products in the</unique_string><TotalNumberUniquestring>2</TotalNumberUniquestring><currentNumberUniquestring>1</currentNumberUniquestring><div_OR_table_navigatin_instructions><divORTableForward_skip>1</divORTableForward_skip> <divForward_in>1</divForward_in></div_OR_table_navigatin_instructions><type_of_product_substring>SEARCH</type_of_product_substring><where_to_search_the_name>title</where_to_search_the_name><currency>$</currency><price_extraction_start_Key>$</price_extraction_start_Key><price_extraction_end_Key>&lt</price_extraction_end_Key>" filename_mode
/src/cpp/test-pages/FrontLoad.html

下面是Eclipse在控制台中打印的内容

/bin/bash: -c: line 0: syntax error near unexpected token `<'
/bin/bash: -c: line 0: `exec /media/Debug/gcom_au 168815 blabla/ product_group_and_eshop_global_id blaee/test/test "<unique_string>products in the</unique_string><TotalNumberUniquestring>2</TotalNumberUniquestring><currentNumberUniquestring>1</currentNumberUniquestring><div_OR_table_navigatin_instructions><divORTableForward_skip>1</divORTableForward_skip> <divForward_in>1</divForward_in></div_OR_table_navigatin_instructions><type_of_product_substring>SEARCH</type_of_product_substring><where_to_search_the_name>title</where_to_search_the_name><currency>$</currency><price_extraction_start_Key>$</price_extraction_start_Key><price_extraction_end_Key>&lt</price_extraction_end_Key>" filename_mode
/src/cpp/test-pages/FrontLoad.html'

我找到了解决方案:我将"更改为"

168815 blabla/ product_group_and_eshop_global_id blaee/test/test "<unique_string>products in the</unique_string><TotalNumberUniquestring>2</TotalNumberUniquestring><currentNumberUniquestring>1</currentNumberUniquestring><div_OR_table_navigatin_instructions><divORTableForward_skip>1</divORTableForward_skip> <divForward_in>1</divForward_in></div_OR_table_navigatin_instructions><type_of_product_substring>SEARCH</type_of_product_substring><where_to_search_the_name>title</where_to_search_the_name><currency>$</currency><price_extraction_start_Key>$</price_extraction_start_Key><price_extraction_end_Key>&lt</price_extraction_end_Key>" filename_mode /src/cpp/test-pages/FrontLoad.html

成为

168815 blabla/ product_group_and_eshop_global_id blaee/test/test '<unique_string>products in the</unique_string><TotalNumberUniquestring>2</TotalNumberUniquestring><currentNumberUniquestring>1</currentNumberUniquestring><div_OR_table_navigatin_instructions><divORTableForward_skip>1</divORTableForward_skip> <divForward_in>1</divForward_in></div_OR_table_navigatin_instructions><type_of_product_substring>SEARCH</type_of_product_substring><where_to_search_the_name>title</where_to_search_the_name><currency>$</currency><price_extraction_start_Key>$</price_extraction_start_Key><price_extraction_end_Key>&lt</price_extraction_end_Key>' filename_mode /src/cpp/test-pages/FrontLoad.html

最新更新