Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Doug Evans <dje@google.com>
To: Don Breazeal <donb@codesourcery.com>
Cc: <gdb-patches@sourceware.org>
Subject: Re: [PATCH v4] PR 18303, Tolerate malformed input for lookup_symbol-called functions.
Date: Tue, 15 Mar 2016 20:30:00 -0000	[thread overview]
Message-ID: <e89a8ffbadef290735052e1c44a3@google.com> (raw)

Don Breazeal writes:
  > Apologies -- the previous version of this patch was missing one file,
  > added here.  Sorry for the noise.
  > --Don
  >
  > ---V3 Comment---
  > This patch differs from v2 in that the new test  
gdb.linespec/ls-errs-cp.exp
  > is gone, and instead (per Pedro's suggestion) gdb.linespec/ls-errs.exp  
has
  > been modified to test both C & C++, and to incorporate the small amount  
of
  > extra testing from ls-errs-cp.exp.
  >
  > It also includes, unchanged from the previous version of the patch:
  >
  >  * an updated version of the alternate fix that Keith proposed for my
  >    patch that addressed PR breakpoints/18303.  Doug has approved (in
  >    concept, at least) the code portion of the patch.
  >
  >  * a couple of other new tests of colons in linespecs.
  >
  > Thanks,
  > --Don
  >
  > -----------
  > lookup_symbol is often called with user input.  Consequently, any
  > function called from lookup_symbol{,_in_language} should attempt to
  > deal with malformed input gracefully.  After all, malformed user
  > input is not a programming/API error.
  >
  > This patch does not attempt to find/correct all instances of this.  It
  > only fixes locations in the code that trigger test suite failures.
  >
  > This patch fixes PR breakpoints/18303, "Assertion: -breakpoint-insert
  > with windows paths of file in non-current directory".
  >
  > The patch includes three new tests related to this.  One is just
  > gdb.linespec/ls-errs.exp copied and converted to use C++ instead of C,  
and
  > to add a case using a file name containing a Windows-style logical drive
  > specifier.  The others include an MI test to provide a regression test  
for
  > the specific case reported in PR 18303, and a C++ test for proper error
  > handling of access to a program variable when using a file scope  
specifier
  > that refers to a non-existent file.
  >
  > Tested on x86_64 native Linux.
  >
  > gdb/ChangeLog
  > 2016-01-28  Keith Seitz  <keiths@redhat.com>
  >
  > 	PR breakpoints/18303
  > 	* cp-namespace.c (cp_lookup_bare_symbol): Change assertion to
  > 	look for "::" instead of simply ":".
  > 	(cp_search_static_and_baseclasses): Return null_block_symbol for
  > 	malformed input.
  > 	Remove assertions.
  > 	* cp-support.c (cp_find_first_component_aux): Do not return
  > 	a prefix length for ':' unless the next character is also ':'.
  >
  > gdb/testsuite/ChangeLog
  > 2016-01-28  Don Breazeal  <donb@codesourcery.com>
  >
  > 	* gdb.cp/scope-err.cc: New test program.
  > 	* gdb.cp/scope-err.exp: New test script.
  > 	* gdb.linespec/ls-errs.c (myfunction): Expanded to have multiple
  > 	lines and "set breakpoint here" comment.
  > 	* gdb.linespec/ls-errs.exp: Added C++ testing and new test case.
  > 	* gdb.mi/mi-linespec-err-cp.cc: New test program.
  > 	* gdb.mi/mi-linespec-err-cp.exp: New test script.
  >...

Hi.
LGTM


             reply	other threads:[~2016-03-15 20:30 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-15 20:30 Doug Evans [this message]
2016-03-15 22:31 ` Don Breazeal
  -- strict thread matches above, loose matches on Subject: below --
2016-01-28 22:43 [PATCH v3] " Don Breazeal
2016-01-28 22:52 ` [PATCH v4] " Don Breazeal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e89a8ffbadef290735052e1c44a3@google.com \
    --to=dje@google.com \
    --cc=donb@codesourcery.com \
    --cc=gdb-patches@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox