diff options
author | Mark Kettenis <kettenis@gnu.org> | 2005-07-18 21:00:50 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@gnu.org> | 2005-07-18 21:00:50 +0000 |
commit | a9ebfb711a57ea57d82edea173cc7ce0058e8418 (patch) | |
tree | bf64ee7f134785f5fc18b8304905878dc8995a1f /gdb/bsd-uthread.c | |
parent | 9c1e93d5eecdbe9385aad962cd95fefd5d7f045e (diff) | |
download | gdb-a9ebfb711a57ea57d82edea173cc7ce0058e8418.tar.gz |
* target.c (normal_pid_to_str): Use xsnprintf instead of snprintf.
* bsd-uthread.c (bsd_uthread_pid_to_str): Likewise.
* inf-ttrace.c (inf_ttrace_pid_to_str): Likewise.
Diffstat (limited to 'gdb/bsd-uthread.c')
-rw-r--r-- | gdb/bsd-uthread.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/gdb/bsd-uthread.c b/gdb/bsd-uthread.c index aa3425d73f9..9004b408473 100644 --- a/gdb/bsd-uthread.c +++ b/gdb/bsd-uthread.c @@ -469,11 +469,9 @@ bsd_uthread_pid_to_str (ptid_t ptid) if (ptid_get_tid (ptid) != 0) { static char buf[64]; - int size; - size = snprintf (buf, sizeof buf, "process %d, thread 0x%lx", - ptid_get_pid (ptid), ptid_get_tid (ptid)); - gdb_assert (size < sizeof buf); + xsnprintf (buf, sizeof buf, "process %d, thread 0x%lx", + ptid_get_pid (ptid), ptid_get_tid (ptid)); return buf; } |