Function n_spaces can't handle negative values, and returns an invalid
pointer in this case.
gdb/ChangeLog:
2021-02-07 Hannes Domani <ssbssa@yahoo.de>
* tui/tui-regs.c (tui_data_item_window::rerender): Don't call
n_spaces with a negative value.
+2021-02-07 Hannes Domani <ssbssa@yahoo.de>
+
+ * tui/tui-regs.c (tui_data_item_window::rerender): Don't call
+ n_spaces with a negative value.
+
2021-02-07 Hannes Domani <ssbssa@yahoo.de>
* tui/tui-regs.c (tui_data_window::display_registers_from):
(void) wstandout (handle);
mvwaddnstr (handle, y, x, content.c_str (), field_width - 1);
- waddstr (handle, n_spaces (field_width - content.size ()));
+ if (content.size () < field_width)
+ waddstr (handle, n_spaces (field_width - content.size ()));
if (highlight)
/* We ignore the return value, casting it to void in order to avoid