aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>1998-07-23 19:20:47 +0000
committerJeff Law <law@redhat.com>1998-07-23 19:20:47 +0000
commit41e9f56c749a0cb06ccea31ad40a6f1f88ad10b8 (patch)
tree4d5f74349238298e392b0a149462d254df2eee0d
parent91b9fccdf0ccb5251c0c4b275d22b07f9c835312 (diff)
downloadgdb-41e9f56c749a0cb06ccea31ad40a6f1f88ad10b8.zip
gdb-41e9f56c749a0cb06ccea31ad40a6f1f88ad10b8.tar.gz
gdb-41e9f56c749a0cb06ccea31ad40a6f1f88ad10b8.tar.bz2
* config/tc-mn10300.c (md_assemble): Make sure "errmsg" has a non-NULL
value.
-rw-r--r--gas/ChangeLog5
-rw-r--r--gas/config/tc-mn10300.c26
2 files changed, 27 insertions, 4 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index acad9be..621a823 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,8 @@
+Thu Jul 23 13:19:50 1998 Jeffrey A Law (law@cygnus.com)
+
+ * config/tc-mn10300.c (md_assemble): Make sure "errmsg" has a non-NULL
+ value.
+
start-sanitize-sky
Wed Jul 22 17:39:28 1998 Frank Ch. Eigler <fche@cygnus.com>
diff --git a/gas/config/tc-mn10300.c b/gas/config/tc-mn10300.c
index c317a17..1dd5803 100644
--- a/gas/config/tc-mn10300.c
+++ b/gas/config/tc-mn10300.c
@@ -152,12 +152,18 @@ static const struct reg_name r_registers[] =
{ "a1", 9 },
{ "a2", 10 },
{ "a3", 11 },
- { "a0", 12 },
+ { "d0", 12 },
{ "d1", 13 },
{ "d2", 14 },
{ "d3", 15 },
{ "e0", 0 },
{ "e1", 1 },
+ { "e10", 10 },
+ { "e11", 11 },
+ { "e12", 12 },
+ { "e13", 13 },
+ { "e14", 14 },
+ { "e15", 15 },
{ "e2", 2 },
{ "e3", 3 },
{ "e4", 4 },
@@ -918,7 +924,7 @@ md_assemble (str)
for(;;)
{
- const char *errmsg = NULL;
+ const char *errmsg = "Invalid opcode/operands";
int op_idx;
char *hold;
int extra_shift = 0;
@@ -954,8 +960,6 @@ md_assemble (str)
next_opindex = 0;
}
- errmsg = NULL;
-
while (*str == ' ' || *str == ',')
++str;
@@ -1256,6 +1260,20 @@ md_assemble (str)
str = hold;
goto error;
}
+ /* start-sanitize-am33 */
+ else if (r_register_name (&ex))
+ {
+ input_line_pointer = hold;
+ str = hold;
+ goto error;
+ }
+ else if (xr_register_name (&ex))
+ {
+ input_line_pointer = hold;
+ str = hold;
+ goto error;
+ }
+ /* end-sanitize-am33 */
else if (*str == ')' || *str == '(')
{
input_line_pointer = hold;