1

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

问题:

当我尝试在 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'
4

1 回答 1

1

我找到了解决方案:我将“更改为”所以。这

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
于 2013-08-25T12:23:10.403 回答