summary refs log tree commit diff
path: root/Src/utils.c
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2008-05-17 17:55:37 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2008-05-17 17:55:37 +0000
commit8ab895baf00686a3d766154d0a07aae92e4475f9 (patch)
treeddbc5e4f265645b1e849560e33ec933c357cc319 /Src/utils.c
parent63b0ca8f378f0c1aa2f3e8858e4e2ea91d645218 (diff)
downloadzsh-8ab895baf00686a3d766154d0a07aae92e4475f9.tar.gz
zsh-8ab895baf00686a3d766154d0a07aae92e4475f9.tar.xz
zsh-8ab895baf00686a3d766154d0a07aae92e4475f9.zip
25057: better debug error on memory failure
Diffstat (limited to 'Src/utils.c')
-rw-r--r--Src/utils.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/Src/utils.c b/Src/utils.c
index a1a97d182..2873e63dc 100644
--- a/Src/utils.c
+++ b/Src/utils.c
@@ -255,6 +255,7 @@ zerrmsg(FILE *file, const char *fmt, va_list ap)
 {
     const char *str;
     int num;
+    long lnum;
 #ifdef HAVE_STRERROR_R
 #define ERRBUFSIZE (80)
     int olderrno;
@@ -286,6 +287,12 @@ zerrmsg(FILE *file, const char *fmt, va_list ap)
 		nicezputs(s, file);
 		break;
 	    }
+#ifdef DEBUG
+	    case 'L':
+		lnum = va_arg(ap, long);
+		fprintf(file, "%ld", lnum);
+		break;
+#endif
 	    case 'd':
 		num = va_arg(ap, int);
 		fprintf(file, "%d", num);