aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-rx.c
diff options
context:
space:
mode:
Diffstat (limited to 'gas/config/tc-rx.c')
-rw-r--r--gas/config/tc-rx.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/gas/config/tc-rx.c b/gas/config/tc-rx.c
index e0af5b5..2c7af20 100644
--- a/gas/config/tc-rx.c
+++ b/gas/config/tc-rx.c
@@ -531,10 +531,7 @@ rx_section (int ignore)
if (*p != '"' && *p != '#')
{
- char * name = (char *) xmalloc (len + 1);
-
- strncpy (name, input_line_pointer, len);
- name[len] = 0;
+ char *name = xmemdup0 (input_line_pointer, len);
input_line_pointer = p;
parse_rx_section (name);