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
x-terminal-emulator gdb.attach not working properly #2362
Comments
Try |
thank you for your reply,I used the update-alternatives --display x-terminal-emulator command to show that the terminal in use is /usr/bin/gnome-terminal.wrapper ╰─$ update-alternatives --display x-terminal-emulator
x-terminal-emulator - auto mode
link best version is /usr/bin/gnome-terminal.wrapper
link currently points to /usr/bin/gnome-terminal.wrapper
link x-terminal-emulator is /usr/bin/x-terminal-emulator
slave x-terminal-emulator.1.gz is /usr/share/man/man1/x-terminal-emulator.1.gz
/usr/bin/gnome-terminal.wrapper - priority 40
slave x-terminal-emulator.1.gz: /usr/share/man/man1/gnome-terminal.1.gz
/usr/bin/koi8rxterm - priority 20
slave x-terminal-emulator.1.gz: /usr/share/man/man1/koi8rxterm.1.gz
/usr/bin/lxterm - priority 30
slave x-terminal-emulator.1.gz: /usr/share/man/man1/lxterm.1.gz
/usr/bin/uxterm - priority 20
slave x-terminal-emulator.1.gz: /usr/share/man/man1/uxterm.1.gz
/usr/bin/xterm - priority 20
slave x-terminal-emulator.1.gz: /usr/share/man/man1/xterm.1.gz
╭─ubuntu@ubuntu-virtual-machine ~
╰─$ update-alternatives --config x-terminal-emulator
There are 5 choices for the alternative x-terminal-emulator (providing /usr/bin/x-terminal-emulator).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/gnome-terminal.wrapper 40 auto mode
1 /usr/bin/gnome-terminal.wrapper 40 manual mode
2 /usr/bin/koi8rxterm 20 manual mode
3 /usr/bin/lxterm 30 manual mode
4 /usr/bin/uxterm 20 manual mode
5 /usr/bin/xterm 20 manual mode
Press <enter> to keep the current choice[*], or type selection number:
|
Oh! I maybe understand what you mean. I tried changing it to xterm and found that it can be attached normally. |
Hello, I attempted to update the code to match the terminal containing 'gnome-terminal' in the symbolic link name for 'x-terminal', and to increment the PID by 1. Does this seem reasonable? Thank you very much. |
pwntools version
Testcase
test.c
exp.py
Debug Output
When I used gdb.attach in x-terminal on ubuntu20.04 to debug, I got an error. I think maybe run_new_terminal returned the wrong gdb_pid so I tried +1 it and found that it worked normally #2363
environ
The text was updated successfully, but these errors were encountered: