diff lib/cache.c @ 249:094e83b55cb1

2003-8-7 Brian Masney <masneyb@gftp.org> * lib/cache.c lib/misc.c lib/protocols.c lib/pty.c - make sure a NUL byte appears at the end of the buffer after the call to strncpy * lib/rfc959.c - increased buffer size to directory parsing routine
author masneyb
date Fri, 08 Aug 2003 02:24:54 +0000
parents 007145d7d975
children a46c2eef5139
line wrap: on
line diff
--- a/lib/cache.c	Fri Aug 08 01:38:12 2003 +0000
+++ b/lib/cache.c	Fri Aug 08 02:24:54 2003 +0000
@@ -310,6 +310,7 @@
   else if (descr != NULL)
     { 
       strncpy (description, descr, sizeof (description));
+      description[sizeof (description) - 1] = '\0';
     }
   else
     return;