Bug 21979 - Make show args show CLI arguments passed via gdbserver
Summary: Make show args show CLI arguments passed via gdbserver
Status: RESOLVED DUPLICATE of bug 21980
Alias: None
Product: gdb
Classification: Unclassified
Component: server (show other bugs)
Version: 7.11
: P2 enhancement
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-08-20 11:16 UTC by Ciro Santilli
Modified: 2017-08-20 12:57 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ciro Santilli 2017-08-20 11:16:29 UTC
Current behavior is a bit confusing:

    gdbserver :1234 ./prog.out arg0 arg1
    gdb -ex 'target remote :1234' ./prog.out
    
Then:

    (gdb) b main
    (gdb) c
    (gdb) show args
    Argument list to give program being debugged when it is started is ""
    (gdb) print argc
    $1 = 3

Would require sending the arguments over the protocol I expect.
Comment 1 Andreas Schwab 2017-08-20 12:57:19 UTC
dup

*** This bug has been marked as a duplicate of bug 21980 ***