diff options
author | Alan Coopersmith <alan.coopersmith@sun.com> | 2007-11-26 13:21:18 -0800 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@sun.com> | 2007-11-26 13:21:18 -0800 |
commit | 6f4560e2ad81736127d2d3544415a05d41e8a2a7 (patch) | |
tree | 6c53b2585d1081cf9296c09cd22acee1e9ac9a4f /save.c | |
parent | fab9dcb15024996ac3a4f94d65ba73f484820534 (diff) |
Use snprintf, strdup & remove instead of sprintf, malloc/strcpy & unlink
Diffstat (limited to 'save.c')
-rw-r--r-- | save.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -147,7 +147,7 @@ MakeCurrentSession(String new_name, Bool name_changed) LockSession (session_name, True); - sprintf (title, "xsm: %s", session_name); + snprintf (title, sizeof(title), "xsm: %s", session_name); XtVaSetValues (topLevel, XtNtitle, title, @@ -413,7 +413,7 @@ SaveOkXtProc(Widget w, XtPointer client_data, XtPointer callData) { name_locked = True; - sprintf (label, "Another session by the name '%s' is active.\nChoose another name for the session.", name); + snprintf (label, sizeof(label), "Another session by the name '%s' is active.\nChoose another name for the session.", name); XtUnmanageChild (nameInUseOverwriteButton); |