Mercurial > pidgin
changeset 3574:2b43124e8475
[gaim-migrate @ 3673]
use snprintf instead of sprintf
committer: Tailor Script <tailor@pidgin.im>
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Mon, 30 Sep 2002 04:23:24 +0000 |
parents | 163205125ee2 |
children | 0a60fd3905b1 |
files | ChangeLog src/protocols/oscar/oscar.c |
diffstat | 2 files changed, 4 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Mon Sep 30 01:29:08 2002 +0000 +++ b/ChangeLog Mon Sep 30 04:23:24 2002 +0000 @@ -75,6 +75,7 @@ Panel Notification Area applet for GNOME 2, or the kicker for KDE 3.1. (Thanks Robert McQueen, Ari Pollak, Patrick Aussems) * Plugins dialog and perl script menu merged into preferences. + * use snprintf instead of sprintf (Thanks William T. Mahan). version 0.59 (06/24/2002): * Hungarian translation added (Thanks, Sutto Zoltan)
--- a/src/protocols/oscar/oscar.c Mon Sep 30 01:29:08 2002 +0000 +++ b/src/protocols/oscar/oscar.c Mon Sep 30 04:23:24 2002 +0000 @@ -398,7 +398,7 @@ c->inpa = 0; c->fd = -1; aim_conn_kill(odata->sess, &conn); - sprintf(buf, _("You have been disconnected from chat room %s."), c->name); + snprintf(buf, sizeof(buf), _("You have been disconnected from chat room %s."), c->name); do_error_dialog(buf, NULL, GAIM_ERROR); } else if (conn->type == AIM_CONN_TYPE_CHATNAV) { if (odata->cnpa > 0) @@ -1822,7 +1822,7 @@ destn = va_arg(ap, char *); va_end(ap); - sprintf(buf, _("Your message to %s did not get sent:"), destn); + snprintf(buf, sizeof(buf), _("Your message to %s did not get sent:"), destn); do_error_dialog(buf, (reason < msgerrreasonlen) ? msgerrreason[reason] : _("No reason was given."), GAIM_ERROR); return 1; @@ -1839,7 +1839,7 @@ destn = va_arg(ap, char *); va_end(ap); - sprintf(buf, _("User information for %s unavailable:"), destn); + snprintf(buf, sizeof(buf), _("User information for %s unavailable:"), destn); do_error_dialog(buf, (reason < msgerrreasonlen) ? msgerrreason[reason] : _("No reason was given."), GAIM_ERROR); return 1;