From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 353723858D39; Tue, 1 Aug 2023 22:39:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 353723858D39 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1690929541; bh=2jJZFPCTEqG1DYGqehnsR7WiIUHcQ7U5Ln8e2CvaTLw=; h=From:To:Subject:Date:From; b=Ql+472na/dn0M8fgJhGuJ2rcUjjV9zuJmsTH6vCjoInxhChjgggdvswCn9PpUulTG N3zchoUsV5Tn4nxmrsXdGrbYgoz7ug3nv3mxXoS9yNuWG6ae+89vBEQwtLuLB8/i9h 2ALvAlavjmT9r1ck5WPktMNRJkowa2mNw53aWFss= From: "tromey at sourceware dot org" To: gdb-prs@sourceware.org Subject: [Bug gdb/30713] New: do not catch 'const gdb_exception &' Date: Tue, 01 Aug 2023 22:39:00 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new 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: tromey at sourceware dot org X-Bugzilla-Status: NEW 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: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: 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 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D30713 Bug ID: 30713 Summary: do not catch 'const gdb_exception &' Product: gdb Version: HEAD Status: NEW Severity: normal Priority: P2 Component: gdb Assignee: unassigned at sourceware dot org Reporter: tromey at sourceware dot org Target Milestone: --- Right now a fair amount of code looks like: try ... catch (const gdb_exception &) ... stuff However,this can end up swallowing a QUIT if one is not careful. I think it would be better to catch 'const gdb_exception_error &' in nearly every spot. One question is what to do with this: struct gdb_quit_bad_alloc : public gdb_exception_quit, public std::bad_alloc I don't know why it derives from the _quit form and not _error. Perhaps that's fine, though, since it would just end up returning to the top level. --=20 You are receiving this mail because: You are on the CC list for the bug.=