s3: Lift the smbd_messaging_context from smbd_sig_hup_handler
authorVolker Lendecke <vl@samba.org>
Sun, 8 Aug 2010 13:15:01 +0000 (15:15 +0200)
committerVolker Lendecke <vl@samba.org>
Sun, 8 Aug 2010 16:09:33 +0000 (18:09 +0200)
source3/smbd/process.c

index 8e97d4086ff1bfa233003d14f425995561fa4c67..9e7b73d2d13fcdbab1f17811af556bdcaa5d2bf6 100644 (file)
@@ -910,9 +910,11 @@ static void smbd_sig_hup_handler(struct tevent_context *ev,
                                  void *siginfo,
                                  void *private_data)
 {
+       struct messaging_context *msg_ctx = talloc_get_type_abort(
+               private_data, struct messaging_context);
        change_to_root_user();
        DEBUG(1,("Reloading services after SIGHUP\n"));
-       reload_services(smbd_messaging_context(), False);
+       reload_services(msg_ctx, False);
 }
 
 void smbd_setup_sig_hup_handler(void)
@@ -923,7 +925,7 @@ void smbd_setup_sig_hup_handler(void)
                               smbd_event_context(),
                               SIGHUP, 0,
                               smbd_sig_hup_handler,
-                              NULL);
+                              smbd_messaging_context());
        if (!se) {
                exit_server("failed to setup SIGHUP handler");
        }