From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id B44473857C71; Fri, 16 Apr 2021 20:20:33 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B44473857C71 From: "simark at simark dot ca" To: gdb-prs@sourceware.org Subject: [Bug gdb/11969] "catch exec" does not work with follow-exec-mode=new Date: Fri, 16 Apr 2021 20:20:33 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: gdb X-Bugzilla-Version: HEAD X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: simark at simark dot ca X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gdb-prs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-prs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Apr 2021 20:20:33 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D11969 Simon Marchi changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |simark at simark dot ca --- Comment #1 from Simon Marchi --- I just tried this, it seems to work: $ ./gdb -q -nx --data-directory=3Ddata-directory --args ./execer args-for-e= xecer Reading symbols from ./execer... (gdb) set follow-exec-mode new (gdb) start Temporary breakpoint 1 at 0x1158: file execer.c, line 5. Starting program: /home/simark/build/binutils-gdb/gdb/execer args-for-execer Temporary breakpoint 1, main (argc=3D2, argv=3D0x7fffffffdf58) at execer.c:5 a5 printf("I am execer and my argv[1] is: %s\n", argv[1]); (gdb) catch exec Catchpoint 2 (exec) (gdb) c Continuing. I am execer and my argv[1] is: args-for-execer process 1483262 is executing new program: /home/simark/build/binutils-gdb/gdb/execee [New inferior 2] [New process 1483262] Thread 2.1 "execee" hit Catchpoint 2 (exec'd /home/simark/build/binutils-gdb/gdb/execee), 0x00007ffff7fcd090 in _start () from /lib64/ld-linux-x86-64.so.2 (gdb) info inferiors=20 Num Description Connection Executable=20=20=20=20=20=20= =20=20 1 1 (native)=20=20=20=20=20=20=20=20=20=20 /home/simark/build/binutils-gdb/gdb/execer=20 * 2 process 1483262 1 (native)=20=20=20=20=20=20=20=20=20=20 /home/simark/build/binutils-gdb/gdb/execee=20 Would you like to test your original use case again, or can we close this? = I think that the test case gdb.base/catch-follow-exec.exp covers this now. --=20 You are receiving this mail because: You are on the CC list for the bug.=