Skip to content

Instantly share code, notes, and snippets.

@reyammer
Created October 7, 2019 16:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save reyammer/55bef4be1281b3e7a33e0a16f8bffbfa to your computer and use it in GitHub Desktop.
Save reyammer/55bef4be1281b3e7a33e0a16f8bffbfa to your computer and use it in GitHub Desktop.
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.3 LTS
Release: 18.04
Codename: bionic
$ dpkg -l | grep gdb
ii gdb 8.1-0ubuntu3.1 amd64 GNU Debugger
$ echo 'int main() {puts("ciao");}' > c.c
$ gcc -m32 -o c c.c # note: you need to have "libc6-i386" and "libc6-dev-i386" installed
$ gdb ./c
Reading symbols from ./c...(no debugging symbols found)...done.
(gdb) r
Starting program: /tmp/c
warning: Breakpoint address adjusted from 0xf7fd9be0 to 0xfffffffff7fd9be0.
warning: Breakpoint address adjusted from 0xf7fda195 to 0xfffffffff7fda195.
warning: Breakpoint address adjusted from 0xf7fdbd1c to 0xfffffffff7fdbd1c.
warning: Breakpoint address adjusted from 0xf7fdb924 to 0xfffffffff7fdb924.
warning: Breakpoint address adjusted from 0xf7fe99b3 to 0xfffffffff7fe99b3.
warning: Breakpoint address adjusted from 0xf7fea401 to 0xfffffffff7fea401.
warning: Breakpoint address adjusted from 0xf7fea706 to 0xfffffffff7fea706.
// hangs without a chance to unstuck it
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment