diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 6f0bc08067..94eb3c628e 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2000-09-01 Kevin Buettner + + * symtab.c (decode_line_1): Make sure leading character is + actually a colon before skipping over leading colons in global + namespace specification. + 2000-09-01 Michael Snyder * regcache.c (reg_flush_command): New function. Maintainer-mode diff --git a/gdb/symtab.c b/gdb/symtab.c index f48368f2e2..2e83933b5b 100644 --- a/gdb/symtab.c +++ b/gdb/symtab.c @@ -2642,7 +2642,8 @@ decode_line_1 (char **argptr, int funfirstline, struct symtab *default_symtab, /* First check for "global" namespace specification, of the form "::foo". If found, skip over the colons and jump to normal symbol processing */ - if ((*argptr == p) || (p[-1] == ' ') || (p[-1] == '\t')) + if (p[0] == ':' + && ((*argptr == p) || (p[-1] == ' ') || (p[-1] == '\t'))) saved_arg2 += 2; /* We have what looks like a class or namespace