summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/nmbd/nmbd.c8
-rw-r--r--source3/smbd/server.c8
-rw-r--r--source3/winbindd/winbindd.c8
3 files changed, 21 insertions, 3 deletions
diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c
index 5678c8e848..fcbe50842d 100644
--- a/source3/nmbd/nmbd.c
+++ b/source3/nmbd/nmbd.c
@@ -780,9 +780,15 @@ static bool open_sockets(bool isdaemon, int port)
POPT_COMMON_SAMBA
{ NULL }
};
- TALLOC_CTX *frame = talloc_stackframe(); /* Setup tos. */
+ TALLOC_CTX *frame;
NTSTATUS status;
+ /*
+ * Do this before any other talloc operation
+ */
+ talloc_enable_null_tracking();
+ frame = talloc_stackframe();
+
load_case_tables();
global_nmb_port = NMB_PORT;
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index 07261b1e83..106eafcccd 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -857,11 +857,17 @@ extern void build_options(bool screen);
POPT_TABLEEND
};
struct smbd_parent_context *parent = NULL;
- TALLOC_CTX *frame = talloc_stackframe(); /* Setup tos. */
+ TALLOC_CTX *frame;
NTSTATUS status;
uint64_t unique_id;
struct rpc_srv_callbacks spoolss_cb;
+ /*
+ * Do this before any other talloc operation
+ */
+ talloc_enable_null_tracking();
+ frame = talloc_stackframe();
+
/* Initialize the event context, it will panic on error */
smbd_event_context();
diff --git a/source3/winbindd/winbindd.c b/source3/winbindd/winbindd.c
index 0c9cdcf52e..d2344fd696 100644
--- a/source3/winbindd/winbindd.c
+++ b/source3/winbindd/winbindd.c
@@ -1124,9 +1124,15 @@ int main(int argc, char **argv, char **envp)
};
poptContext pc;
int opt;
- TALLOC_CTX *frame = talloc_stackframe();
+ TALLOC_CTX *frame;
NTSTATUS status;
+ /*
+ * Do this before any other talloc operation
+ */
+ talloc_enable_null_tracking();
+ frame = talloc_stackframe();
+
/* glibc (?) likes to print "User defined signal 1" and exit if a
SIGUSR[12] is received before a handler is installed */