Project

General

Profile

Bug #1310

ifdef for prctl is checking wrong constant

Added by Anonymous over 11 years ago. Updated over 11 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
-
Category:
core
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Missing in 1.5.x:

Description

In 1.4.16, and possibly earlier, the constant in config.h for prctl was renamed to HAVE_SYS_PRCTL_H, but server.c is not checking it correctly on line 763 to see if it should use prctl to set PR_SET_DUMPABLE. Any server running in drop-privs mode, will not be able to dump core even with server.enable-cores set.


--- server.c    2007-06-15 08:30:34.000000000 -0700
+++ server.c.new        2007-08-21 13:54:00.000000000 -0700
@@ -760,7 +760,7 @@
                        setuid(pwd->pw_uid);
                }
 #endif
-#ifdef HAVE_PRCTL
+#ifdef HAVE_SYS_PRCTL_H
                if (srv->srvconf.enable_cores) {
                        prctl(PR_SET_DUMPABLE, 1, 0, 0, 0);
                }

-- ethan

History

#1

Updated by jan over 11 years ago

  • Status changed from New to Fixed
  • Resolution set to fixed

fixed in r1958

#2

Updated by jan over 11 years ago

and in r1961 in 1.5.0

Also available in: Atom