Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Bug#245974: zsh: export LC_ALL=da_DK causes segfault



Looks to me like you failed to set the first character in buf to a
non-zero value.  Here's a patch.

..wayne..
--- Src/utils.c	4 May 2004 16:43:43 -0000	1.60
+++ Src/utils.c	5 May 2004 04:41:31 -0000
@@ -1834,7 +1834,7 @@ ztrftime(char *buf, int bufsize, char *f
 		 * Remember we've already allowed for two characters
 		 * in the accounting in bufsize (but nowhere else).
 		 */
-		*buf = '\0';
+		*buf = '\1';
 		tmp[1] = fmt[-1];
 		if (!strftime(buf, bufsize + 2, tmp, tm))
 		{


Messages sorted by: Reverse Date, Date, Thread, Author