]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Bug #1334: Can't dump core on Linux when started as root
authorserassio <>
Sat, 24 Sep 2005 19:21:00 +0000 (19:21 +0000)
committerserassio <>
Sat, 24 Sep 2005 19:21:00 +0000 (19:21 +0000)
Don't be as strict about verifying the prctl success. Not all kernels
supports this prctl, but the only downside when not supported is that
there won't be core dumps so there is no reason to report this error at
level 0.

Forward port of 2.5 patch.

src/tools.cc

index 82d408f53b7ced38a5df7dab0b4691718b768f08..988128108a4051df83366de4c40c97d5159eb45f 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: tools.cc,v 1.263 2005/09/17 05:50:08 wessels Exp $
+ * $Id: tools.cc,v 1.264 2005/09/24 13:21:00 serassio Exp $
  *
  * DEBUG: section 21    Misc Functions
  * AUTHOR: Harvest Derived
@@ -709,7 +709,7 @@ leave_suid(void)
 #if HAVE_PRCTL && defined(PR_SET_DUMPABLE)
     /* Set Linux DUMPABLE flag */
     if (Config.coredump_dir && prctl(PR_SET_DUMPABLE, 1) != 0)
-        debug(50, 0) ("ALERT: prctl: %s\n", xstrerror());
+        debug(50, 2) ("ALERT: prctl: %s\n", xstrerror());
 
 #endif
 }
@@ -730,7 +730,7 @@ enter_suid(void)
     /* Set Linux DUMPABLE flag */
 
     if (Config.coredump_dir && prctl(PR_SET_DUMPABLE, 1) != 0)
-        debug(50, 0) ("ALERT: prctl: %s\n", xstrerror());
+        debug(50, 2) ("ALERT: prctl: %s\n", xstrerror());
 
 #endif
 }
@@ -761,7 +761,7 @@ no_suid(void)
 #if HAVE_PRCTL && defined(PR_SET_DUMPABLE)
     /* Set Linux DUMPABLE flag */
     if (Config.coredump_dir && prctl(PR_SET_DUMPABLE, 1) != 0)
-        debug(50, 0) ("ALERT: prctl: %s\n", xstrerror());
+        debug(50, 2) ("ALERT: prctl: %s\n", xstrerror());
 
 #endif
 }