radare2 icon indicating copy to clipboard operation
radare2 copied to clipboard

Issue with doo. dc hangs

Open jattboe opened this issue 2 years ago • 3 comments

Environment

Wed Jan 19 07:41:58 PM IST 2022

radare2 5.5.5 1 @ linux-x86-64 git.
commit: f8f93681bd183582b943fee4be5714e7fbac9d4d build: 2022-01-19__19:18:00

Linux arch 5.16.0-arch1-1 #1 SMP PREEMPT Mon, 10 Jan 2022 20:11:47 +0000 x86_64 GNU/Linux

Description

Simply open a binary with r2

  • r2 -AA binary

Then used doo to Reopen in debug mode with args (alias for 'ood')

  • doo

Then simply run dc - continue execution of all children

(49475) Process exited with status=0x0

Again run dc - now process is completely terminated

(49475) Process terminated with status 0

==> Process finished

now the intended behaviour must be running doo again and will be in debug mode. But

After running doo. when you'll run dc it hangs.

On the other side running doo twice and then running dc works fine,

jattboe avatar Jan 19 '22 16:01 jattboe

I also have this issue. I run binary with dc, then ood after it finishes running to run again, and dc, which hangs it.

I went onto discord to ask for help and figured that running doc to close the debug, before running ood, will prevent it from hanging when running dc again, so this is a workaround for now.

I've tried on 3 versions, 5.5.0 which was preinstalled on kali linux, 5.7.9 after updating by cloning this repo. Both of these versions have this issue. However, on Windows Subsystem for Linux (WSL) on version 4.2.1, it does not have this issue.

TheSavageTeddy avatar Nov 26 '22 13:11 TheSavageTeddy

I can repro on mac too

trufae avatar May 22 '23 12:05 trufae

I am also having this issue on Arch. This happens to me often: I want to run the binary I have open in debug mode so I dc. Then I decide I want to run it again (but forget to reopen with ood) so I run dc again. Now I realize that I forgot to repoen so I run ood followed by dc and r2 hangs.

[chris@archbox radare2]$ r2 -v
radare2 5.8.9 31002 @ linux-x86-64
birth: git.5.8.8-381-ge3f5456bd7 2023-08-02__14:30:49
commit: e3f5456bd74f84a961688013fcc7b4f6a670a2cb
options: gpl -O? cs:5 cl:2 make
[chris@archbox radare2]$ uname -ms
Linux x86_64
[chris@archbox radare2]$ r2 -d /bin/ls
 -- radare2 is WYSIWYF - what you see is what you fix
[0x7fdd25b44d70]> dc
autogen.sh    configure      configure.hook     config-user.mk.acr  COPYING.LESSER  doc        INSTALL.md  Makefile     meson_options.txt  plugins.cfg       README.md    sys       vsfix.bat
binr          configure.acr  configure-plugins  CONTRIBUTING.md     DEVELOPERS.md   env.sh     libr        man          mk                 preconfigure      SECURITY.md  test
COMMUNITY.md  configure.bat  config-user.mk     COPYING             dist            global.mk  make.bat    meson.build  pkgcfg             preconfigure.bat  shlr         USAGE.md
(113494) Process exited with status=0x0
[0x7fdd259debad]> dc
(113494) Process terminated with status 0
INFO: ==> Process finished
[0x7fdd25b44d70]> ood
INFO: File dbg:///usr/bin/ls reopened in read-write mode
[0x7fa75db9cd70]> dc

Chris-F5 avatar Aug 02 '23 14:08 Chris-F5