remove use of sprintf in py-finishbreakpoint.c...
... and replace it with call to xsnprintf, following GDB's coding rules. gdb/ChangeLog: * py-finishbreakpoint.c (bpfinishpy_init): Replace call to sprintf by call to xsnprintf.
This commit is contained in:
parent
095bcf5ed3
commit
41843fe8ff
2 changed files with 6 additions and 1 deletions
|
@ -277,7 +277,7 @@ bpfinishpy_init (PyObject *self, PyObject *args, PyObject *kwargs)
|
|||
{
|
||||
/* Set a breakpoint on the return address. */
|
||||
finish_pc = get_frame_pc (prev_frame);
|
||||
sprintf (small_buf, "*%s", hex_string (finish_pc));
|
||||
xsnprintf (small_buf, sizeof (small_buf), "*%s", hex_string (finish_pc));
|
||||
addr_str = small_buf;
|
||||
|
||||
create_breakpoint (python_gdbarch,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue