Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

updating the local variables may hang gdb #206

Open
ZungBang opened this issue May 30, 2018 · 1 comment
Open

updating the local variables may hang gdb #206

ZungBang opened this issue May 30, 2018 · 1 comment

Comments

@ZungBang
Copy link

In the program I'm trying to debug there's a local variable which is a class instance with a static member of the same type. This causes gdb to enter an endless loop whenever it is displayed (e.g. with info locals or when generating the response to -stack-list-variables --simple-values), and this causes gdbgui to hang in turn until I send SIGINT to gdb.

I have two suggestions:

  • a workaround: make gdbgui only issue the stack-list-variables query when the locals pane is not collapsed. This way I'll still be able to step through the code by hiding the locals.

  • a possible fix: use -stack-list-variables --no-values to query the locals and function args and then create a var for each (i.e. start "watching" all locals) - this seems to work when I do it manually... (mmm, you'd probably need to remove all the watched locals and re-add them every time the gui is updated)

@cs01
Copy link
Owner

cs01 commented Sep 30, 2018

I like the second option. It would also make the code I have to maintain a little simpler. I will add it to my TODO list :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants