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

Memory errors with Fedora 9 x86_64



Having just upgraded to Fedora 9 x86_64 with kernel 2.6.25.3-18.fc9.x86_64
and gcc 4.3.0, I'm getting occasional memory errors when running the
tests with --enable-zsh-mem (which may or may not cause the test to
fail, and are apparently random).  I added the following debugging and the
memory requested doesn't seem out of the ordinary.  Is anyone else
seeing anything similar?

It's possible --enable-zsh-mem has simply had it's day.  I'm not seeing
any errors without that, but it's also possible this is a genuine system
problem.

Index: Src/mem.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/mem.c,v
retrieving revision 1.15
diff -u -r1.15 mem.c
--- Src/mem.c	30 Apr 2007 09:27:23 -0000	1.15
+++ Src/mem.c	17 May 2008 16:22:27 -0000
@@ -958,7 +958,7 @@
 	n = (size + M_HSIZE + M_ALLOC + m_pgsz - 1) & ~(m_pgsz - 1);
 
 	if (((char *)(m = (struct m_hdr *)sbrk(n))) == ((char *)-1)) {
-	    DPUTS(1, "MEM: allocation error at sbrk.");
+	    DPUTS1(1, "MEM: allocation error at sbrk, size %L.", n);
 	    unqueue_signals();
 	    return NULL;
 	}
Index: Src/utils.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/utils.c,v
retrieving revision 1.191
diff -u -r1.191 utils.c
--- Src/utils.c	15 May 2008 15:51:01 -0000	1.191
+++ Src/utils.c	17 May 2008 16:22:30 -0000
@@ -255,6 +255,7 @@
 {
     const char *str;
     int num;
+    long lnum;
 #ifdef HAVE_STRERROR_R
 #define ERRBUFSIZE (80)
     int olderrno;
@@ -286,6 +287,12 @@
 		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);


-- 
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/



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