[SCM] Samba Shared Repository - branch master updated

Stefan Metzmacher metze at samba.org
Tue Oct 4 04:52:04 MDT 2011


The branch, master has been updated
       via  4c6bfac s3:lib/util: make sure panic action can attach a debugger on ubuntu (>=10.10)
       via  f2b795e lib/util: make sure panic action can attach a debugger on ubuntu (>=10.10)
       via  1ff61f1 s3:param: use ROLE_DOMAIN_CONTROLLER for an AD domain controller
      from  6b5d8e0 s4-subdomain: create trust record with forest root DC

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 4c6bfac12a274b0bbcdb54681a817b704839222d
Author: Stefan Metzmacher <metze at samba.org>
Date:   Tue Oct 4 10:47:46 2011 +0200

    s3:lib/util: make sure panic action can attach a debugger on ubuntu (>=10.10)
    
    By default user processes can't attach a debugger to a process.
    So explicitly allow that for all child processes, before calling
    the panic action script.
    
    metze
    
    Autobuild-User: Stefan Metzmacher <metze at samba.org>
    Autobuild-Date: Tue Oct  4 12:51:35 CEST 2011 on sn-devel-104

commit f2b795e9cf3ddb0f6bf0929bd0e423d39d6d239a
Author: Stefan Metzmacher <metze at samba.org>
Date:   Tue Oct 4 10:47:46 2011 +0200

    lib/util: make sure panic action can attach a debugger on ubuntu (>=10.10)
    
    By default user processes can't attach a debugger to a process.
    So explicitly allow that for all child processes, before calling
    the panic action script.
    
    metze

commit 1ff61f1223f36a7cfa7acfc9da500b2684e5282b
Author: Stefan Metzmacher <metze at samba.org>
Date:   Tue Oct 4 09:21:23 2011 +0200

    s3:param: use ROLE_DOMAIN_CONTROLLER for an AD domain controller
    
    metze

-----------------------------------------------------------------------

Summary of changes:
 lib/util/fault.c                     |    7 +++++++
 source3/lib/util.c                   |   11 +++++++++++
 source3/param/loadparm_server_role.c |    2 +-
 3 files changed, 19 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/lib/util/fault.c b/lib/util/fault.c
index ed7684a..7fe081d 100644
--- a/lib/util/fault.c
+++ b/lib/util/fault.c
@@ -116,6 +116,13 @@ static void smb_panic_default(const char *why)
 {
 	int result;
 
+#if defined(HAVE_PRCTL) && defined(PR_SET_PTRACER)
+	/*
+	 * Make sure all children can attach a debugger.
+	 */
+	prctl(PR_SET_PTRACER, getpid(), 0, 0, 0);
+#endif
+
 	if (panic_action && *panic_action) {
 		char pidstr[20];
 		char cmdstring[200];
diff --git a/source3/lib/util.c b/source3/lib/util.c
index 689d41e..887d184 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -31,6 +31,10 @@
 #include <ccan/hash/hash.h>
 #include "libcli/security/security.h"
 
+#ifdef HAVE_SYS_PRCTL_H
+#include <sys/prctl.h>
+#endif
+
 /* Max allowable allococation - 256mb - 0x10000000 */
 #define MAX_ALLOC_SIZE (1024*1024*256)
 
@@ -778,6 +782,13 @@ void smb_panic_s3(const char *why)
 		    (unsigned long long)sys_getpid(), why));
 	log_stack_trace();
 
+#if defined(HAVE_PRCTL) && defined(PR_SET_PTRACER)
+	/*
+	 * Make sure all children can attach a debugger.
+	 */
+	prctl(PR_SET_PTRACER, getpid(), 0, 0, 0);
+#endif
+
 	cmd = lp_panic_action();
 	if (cmd && *cmd) {
 		DEBUG(0, ("smb_panic(): calling panic action [%s]\n", cmd));
diff --git a/source3/param/loadparm_server_role.c b/source3/param/loadparm_server_role.c
index 3cc8f35..1f18b4f 100644
--- a/source3/param/loadparm_server_role.c
+++ b/source3/param/loadparm_server_role.c
@@ -79,7 +79,7 @@ void set_server_role(void)
 			break;
 		case SEC_ADS:
 			if (lp_domain_logons()) {
-				server_role = ROLE_DOMAIN_PDC;
+				server_role = ROLE_DOMAIN_CONTROLLER;
 				break;
 			}
 			server_role = ROLE_DOMAIN_MEMBER;


-- 
Samba Shared Repository


More information about the samba-cvs mailing list