aboutsummaryrefslogtreecommitdiff
path: root/gas/read.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2001-07-27 08:35:56 +0000
committerAlan Modra <amodra@gmail.com>2001-07-27 08:35:56 +0000
commit409d19c41aeeb7dc21613fdb7efd54e0f3a23c89 (patch)
tree99dcfd2e56d2bf87d610eb1712e9e2031deab33d /gas/read.c
parent411e0b6d6c7194fc44347fa820f6f906b5ab6f45 (diff)
downloadgdb-409d19c41aeeb7dc21613fdb7efd54e0f3a23c89.zip
gdb-409d19c41aeeb7dc21613fdb7efd54e0f3a23c89.tar.gz
gdb-409d19c41aeeb7dc21613fdb7efd54e0f3a23c89.tar.bz2
* read.c (s_set): Check for missing symbol name.
Diffstat (limited to 'gas/read.c')
-rw-r--r--gas/read.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/gas/read.c b/gas/read.c
index de3d9fd..c6ee4ab 100644
--- a/gas/read.c
+++ b/gas/read.c
@@ -2737,6 +2737,15 @@ s_set (equiv)
name = input_line_pointer;
delim = get_symbol_end ();
end_name = input_line_pointer;
+
+ if (name[0] == '\0')
+ {
+ as_bad (_("expected symbol name"));
+ *end_name = delim;
+ discard_rest_of_line ();
+ return;
+ }
+
*end_name = delim;
SKIP_WHITESPACE ();