diff --git a/ChangeLog b/ChangeLog index d2b6e83dd6d0ad5be90362a6503f9e9c33aa5a18..b35deb7d1d7e9460309f57f90bc8629c0d7300a0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -10,6 +10,10 @@ CVS Code - do_preserve_msg(): - Unsplit error message into a single fprintf call (Jordi). +- winio.c: + bottombars() + - Change strcpy of gettext() "Up" string to strncpy of max + width 8, to stop stupid strcpy crash. GNU nano 1.1.99pre1 - 2003.01.17 - General: - New date format for NEWS and ChangeLog. diff --git a/winio.c b/winio.c index 4c95ae1d5e4e11f20d9564411f59bd9526241da5..04b1e38b46ab338ce03a068f140c1817fef54415 100644 --- a/winio.c +++ b/winio.c @@ -564,7 +564,7 @@ void titlebar(const char *path) void bottombars(const shortcut *s) { int i, j, numcols; - char keystr[4]; + char keystr[9]; int slen; if (ISSET(NO_HELP)) @@ -591,7 +591,7 @@ void bottombars(const shortcut *s) strcpy(keystr, "^ "); #ifndef NANO_SMALL else if (s->val == KEY_UP) - strcpy(keystr, _("Up")); + strncpy(keystr, _("Up"), 8); #endif /* NANO_SMALL */ else if (s->val > 0) { if (s->val < 64)