Hi,

I'm preparing an NMU with the attached patch to fix this issue.

Thanks,
-Steve


diff -u -r openmpi-1.3.2/debian/changelog ../openmpi-1.3.2/debian/changelog
--- openmpi-1.3.2/debian/changelog	2009-06-17 21:56:32.000000000 -0500
+++ ../openmpi-1.3.2/debian/changelog	2009-06-17 22:03:31.000000000 -0500
@@ -1,3 +1,13 @@
+openmpi (1.3.2-2.1) unstable; urgency=low
+
+  * NMU
+  * opal/mca/memory/ptmalloc2/hooks.c: Add check for environment variable
+    OMPI_MCA_disable_memory_allocator.  If set, avoid setting up malloc
+    hooks and avoid stat() calls from the malloc init hook.  
+    Closes: #531522.
+
+ -- Steve M. Robbins <s...@debian.org>  Wed, 17 Jun 2009 22:03:31 -0500
+
 openmpi (1.3.2-2) unstable; urgency=low
 
   * Upload to unstable. No changes compared to 1.3.2-1.
Only in ../openmpi-1.3.2/debian: changelog~
Only in ../openmpi-1.3.2/debian/patches: disable-memory-allocator
diff -u -r openmpi-1.3.2/debian/patches/series ../openmpi-1.3.2/debian/patches/series
--- openmpi-1.3.2/debian/patches/series	2009-06-17 21:56:32.000000000 -0500
+++ ../openmpi-1.3.2/debian/patches/series	2009-06-17 21:57:37.000000000 -0500
@@ -1,6 +1,9 @@
 # Fixes build issues on Alpha.
 alpha_build
 
+# Fix 531522.
+disable-memory-allocator
+
 # Fixes build issues on Sparc.
 sparc_build
 
Only in ../openmpi-1.3.2/debian/patches: series~
diff -u -r openmpi-1.3.2/opal/mca/memory/ptmalloc2/hooks.c ../openmpi-1.3.2/opal/mca/memory/ptmalloc2/hooks.c
--- openmpi-1.3.2/opal/mca/memory/ptmalloc2/hooks.c	2009-04-21 22:51:03.000000000 -0500
+++ ../openmpi-1.3.2/opal/mca/memory/ptmalloc2/hooks.c	2009-06-17 21:55:54.000000000 -0500
@@ -725,6 +725,14 @@
     check_result_t lpp = check("OMPI_MCA_mpi_leave_pinned_pipeline");
     bool want_rcache = false, found_driver = false;
 
+    /* Allow user to disable memory allocators.  We check this and
+     * exit early because in some environments (e.g. Debian fakeroot
+     * the stat() calls below will cause a memory allocation, which
+     * is deadly.  See http://bugs.debian.org/531522
+     */
+    if ( RESULT_YES == check("OMPI_MCA_disable_memory_allocator") )
+	return;
+
     /* Look for sentinel files (directories) to see if various network
        drivers are loaded (yes, I know, further abstraction
        violations...).
Only in ../openmpi-1.3.2/opal/mca/memory/ptmalloc2: hooks.c~
Only in ../openmpi-1.3.2: .pc

Attachment: signature.asc
Description: Digital signature

Reply via email to