aboutsummaryrefslogtreecommitdiff
path: root/gdb/stabsread.c
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2007-09-05 00:01:41 +0000
committerMichael Snyder <msnyder@vmware.com>2007-09-05 00:01:41 +0000
commit8fb822e099bd9e67a9bac094852e9bce15ceb175 (patch)
tree27ecb5de3b88aa44e316fc0d0ed43834c75e8bdc /gdb/stabsread.c
parent570b4ee2f781445f1d27e2024fa69a093fa179ad (diff)
downloadgdb-8fb822e099bd9e67a9bac094852e9bce15ceb175.zip
gdb-8fb822e099bd9e67a9bac094852e9bce15ceb175.tar.gz
gdb-8fb822e099bd9e67a9bac094852e9bce15ceb175.tar.bz2
2007-09-04 Michael Snyder <msnyder@access-company.com>
* stabsread.c (patch_block_status): Guard against null. * Makefile.in (stabsread.o): Depend on gdb_assert.h.
Diffstat (limited to 'gdb/stabsread.c')
-rw-r--r--gdb/stabsread.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gdb/stabsread.c b/gdb/stabsread.c
index 410abec..0e09368 100644
--- a/gdb/stabsread.c
+++ b/gdb/stabsread.c
@@ -45,6 +45,7 @@
#include "doublest.h"
#include "cp-abi.h"
#include "cp-support.h"
+#include "gdb_assert.h"
#include <ctype.h>
@@ -359,6 +360,7 @@ patch_block_stabs (struct pending *symbols, struct pending_stabs *stabs,
{
name = stabs->stab[ii];
pp = (char *) strchr (name, ':');
+ gdb_assert (pp); /* Must find a ':' or game's over. */
while (pp[1] == ':')
{
pp += 2;