about summary refs log tree commit diff
path: root/Src/Modules/datetime.c
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2004-05-04 16:43:29 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2004-05-04 16:43:29 +0000
commitf57f65282b8b7de7db638eaabd06867ea8b1162f (patch)
tree64bb58c0fe67fc88c212f6f7fc1b7260400da2e2 /Src/Modules/datetime.c
parentc98b9dc800171365eee34a3adbf5a741dbef69ca (diff)
downloadzsh-f57f65282b8b7de7db638eaabd06867ea8b1162f.tar.gz
zsh-f57f65282b8b7de7db638eaabd06867ea8b1162f.tar.xz
zsh-f57f65282b8b7de7db638eaabd06867ea8b1162f.zip
19877: improved test for empty strftime strings
Diffstat (limited to 'Src/Modules/datetime.c')
-rw-r--r--Src/Modules/datetime.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Src/Modules/datetime.c b/Src/Modules/datetime.c
index 5877b8490..cb85b8e09 100644
--- a/Src/Modules/datetime.c
+++ b/Src/Modules/datetime.c
@@ -61,7 +61,7 @@ bin_strftime(char *nam, char **argv, Options ops, int func)
     buffer = zalloc(bufsize);
 
     for (x=0; x < 4; x++) {
-        if (ztrftime(buffer, bufsize, argv[0], t))
+        if (ztrftime(buffer, bufsize, argv[0], t) >= 0)
 	    break;
 	buffer = zrealloc(buffer, bufsize *= 2);
     }