Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 320629

Summary: MI command -gdb-set does not properly escape argument
Product: [Tools] CDT Reporter: Elena Laskavaia <elaskavaia.cdt>
Component: cdt-debug-cdi-gdbAssignee: Elena Laskavaia <elaskavaia.cdt>
Status: RESOLVED FIXED QA Contact: Elena Laskavaia <elaskavaia.cdt>
Severity: normal    
Priority: P3 CC: pawel.1.piech
Version: 7.0   
Target Milestone: 7.0.1   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
patch elaskavaia.cdt: iplog-

Description Elena Laskavaia CLA 2010-07-22 09:51:42 EDT
For example if argument is a path with spaces such as "/tmp/path with spaces"
command set solib-search-path would be send as 
-gdb-set solib-search-path "/tmp/path with spaces"
which seems logical by gdb does not understand that
it wants 
-gdb-set solib-search-path /tmp/path with spaces
and it does work this way

Unfortunately set has tons of variables and they have own types. But from what I can tell none of them would parse quotes (reading gdb code)
Comment 1 Elena Laskavaia CLA 2010-07-22 09:53:59 EDT
Created attachment 174975 [details]
patch

patch for set command to avoid escaping arguments
Comment 2 Elena Laskavaia CLA 2010-07-23 10:35:13 EDT
fixed on trunk
Comment 4 Elena Laskavaia CLA 2010-07-23 16:03:43 EDT
and fixed on 7.0.1