From: Michael Snyder Date: Wed, 7 Jan 2004 19:14:45 +0000 (+0000) Subject: 2004-01-02 Pawel Ostrowski X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=15255275af6b47151f37826e17e335210c1cd18e;p=binutils-gdb.git 2004-01-02 Pawel Ostrowski * tracepoint.c (validate_actionline): Fix segv at EOF --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 5a4b719b35d..a1442f96290 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2004-01-02 Pawel Ostrowski + + * tracepoint.c (validate_actionline): Fix segv at EOF + 2004-01-07 Michael Chastain * hpread.c (hpread_read_struct_type): Call SET_FIELD_PHYSNAME diff --git a/gdb/tracepoint.c b/gdb/tracepoint.c index 6e33841824f..713bf14f2cc 100644 --- a/gdb/tracepoint.c +++ b/gdb/tracepoint.c @@ -914,6 +914,10 @@ validate_actionline (char **line, struct tracepoint *t) struct cleanup *old_chain = NULL; char *p; + /* if EOF is typed, *line is NULL */ + if (*line == NULL) + return END; + for (p = *line; isspace ((int) *p);) p++;