diff options
Diffstat (limited to 'gas/config/obj-coff-seh.c')
-rw-r--r-- | gas/config/obj-coff-seh.c | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/gas/config/obj-coff-seh.c b/gas/config/obj-coff-seh.c index 2ffefa8..ec53585 100644 --- a/gas/config/obj-coff-seh.c +++ b/gas/config/obj-coff-seh.c @@ -329,8 +329,7 @@ obj_coff_seh_handler (int what ATTRIBUTE_UNUSED) if (*input_line_pointer == '@') { - symbol_name = input_line_pointer; - name_end = get_symbol_end (); + name_end = get_symbol_name (&symbol_name); seh_ctx_cur->handler.X_op = O_constant; seh_ctx_cur->handler.X_add_number = 0; @@ -343,7 +342,7 @@ obj_coff_seh_handler (int what ATTRIBUTE_UNUSED) else as_bad (_("unknown constant value '%s' for handler"), symbol_name); - *input_line_pointer = name_end; + (void) restore_line_pointer (name_end); } else expression (&seh_ctx_cur->handler); @@ -359,8 +358,7 @@ obj_coff_seh_handler (int what ATTRIBUTE_UNUSED) { do { - symbol_name = input_line_pointer; - name_end = get_symbol_end (); + name_end = get_symbol_name (&symbol_name); if (strcasecmp (symbol_name, "@unwind") == 0) seh_ctx_cur->handler_flags |= UNW_FLAG_UHANDLER; @@ -369,7 +367,7 @@ obj_coff_seh_handler (int what ATTRIBUTE_UNUSED) else as_bad (_(".seh_handler constant '%s' unknown"), symbol_name); - *input_line_pointer = name_end; + (void) restore_line_pointer (name_end); } while (skip_whitespace_and_comma (0)); } @@ -454,10 +452,9 @@ obj_coff_seh_proc (int what ATTRIBUTE_UNUSED) SKIP_WHITESPACE (); - symbol_name = input_line_pointer; - name_end = get_symbol_end (); + name_end = get_symbol_name (&symbol_name); seh_ctx_cur->func_name = xstrdup (symbol_name); - *input_line_pointer = name_end; + (void) restore_line_pointer (name_end); demand_empty_rest_of_line (); @@ -549,14 +546,13 @@ seh_x64_read_reg (const char *directive, int kind) SKIP_WHITESPACE (); if (*input_line_pointer == '%') ++input_line_pointer; - symbol_name = input_line_pointer; - name_end = get_symbol_end (); + name_end = get_symbol_name (& symbol_name); for (i = 0; i < 16; i++) if (! strcasecmp (regs[i], symbol_name)) break; - *input_line_pointer = name_end; + (void) restore_line_pointer (name_end); /* Error if register not found, or EAX used as a frame pointer. */ if (i == 16 || (kind == 0 && i == 0)) |