mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-27 09:38:57 +00:00
2007-09-04 Michael Snyder <msnyder@access-company.com>
* expprint.c (print_subexp_standard): Check strchr for null. * Makefile.in (expprint.o): Depend on gdb_assert.h.
This commit is contained in:
@@ -30,6 +30,7 @@
|
||||
#include "gdb_string.h"
|
||||
#include "block.h"
|
||||
#include "objfiles.h"
|
||||
#include "gdb_assert.h"
|
||||
|
||||
#ifdef HAVE_CTYPE_H
|
||||
#include <ctype.h>
|
||||
@@ -212,6 +213,7 @@ print_subexp_standard (struct expression *exp, int *pos,
|
||||
for (tem = 0; tem < nargs; tem++)
|
||||
{
|
||||
nextS = strchr (s, ':');
|
||||
gdb_assert (nextS); /* Make sure we found ':'. */
|
||||
*nextS = '\0';
|
||||
fprintf_unfiltered (stream, " %s: ", s);
|
||||
s = nextS + 1;
|
||||
|
||||
Reference in New Issue
Block a user