The branch, master has been updated
       via  62249f7 s3: Use pid_to_procid
       via  7b60729 s3: Fix some nonempty blank lines
       via  7a489ec s3: Remove a call to procid_self()
       via  c863d65 s3: Remove a call to procid_self()
       via  80b4a3a s3: Remove a call to procid_self()
       via  4066e29 s3: Remove a call to procid_self()
      from  2142405 s4-provision: Do not guess partition file names, use 
@PARTITION record

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


- Log -----------------------------------------------------------------
commit 62249f755a333f9265395a292af5b8a31b6825ad
Author: Volker Lendecke <v...@samba.org>
Date:   Tue Dec 13 11:02:21 2011 +0100

    s3: Use pid_to_procid
    
    Autobuild-User: Volker Lendecke <vlen...@samba.org>
    Autobuild-Date: Tue Dec 13 12:35:09 CET 2011 on sn-devel-104

commit 7b60729d5a37a2427e35b87990058c23c8155c9d
Author: Volker Lendecke <v...@samba.org>
Date:   Tue Dec 13 11:00:16 2011 +0100

    s3: Fix some nonempty blank lines

commit 7a489ec7808824d307400feaddbc7934cb008f9e
Author: Volker Lendecke <v...@samba.org>
Date:   Tue Dec 13 10:57:34 2011 +0100

    s3: Remove a call to procid_self()

commit c863d65d1b6a116617bfafbfab9dc05abdfe86bc
Author: Volker Lendecke <v...@samba.org>
Date:   Tue Dec 13 10:57:09 2011 +0100

    s3: Remove a call to procid_self()

commit 80b4a3aadc65628e3873d01e76d8644da69cd730
Author: Volker Lendecke <v...@samba.org>
Date:   Tue Dec 13 10:56:32 2011 +0100

    s3: Remove a call to procid_self()

commit 4066e291f56dbc084407fe10aeee168a1d497807
Author: Volker Lendecke <v...@samba.org>
Date:   Tue Dec 13 10:56:27 2011 +0100

    s3: Remove a call to procid_self()

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

Summary of changes:
 source3/nmbd/nmbd.c              |   20 ++++++++++----------
 source3/printing/queue_process.c |    2 +-
 source3/smbd/server.c            |   12 ++++++------
 3 files changed, 17 insertions(+), 17 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c
index f61220b..7dff92a 100644
--- a/source3/nmbd/nmbd.c
+++ b/source3/nmbd/nmbd.c
@@ -64,13 +64,13 @@ struct messaging_context *nmbd_messaging_context(void)
 static void terminate(void)
 {
        DEBUG(0,("Got SIGTERM: going down...\n"));
-  
+
        /* Write out wins.dat file if samba is a WINS server */
        wins_write_database(0,False);
-  
+
        /* Remove all SELF registered names from WINS */
        release_wins_names();
-  
+
        /* Announce all server entries as 0 time-to-live, 0 type. */
        announce_my_servers_removed();
 
@@ -168,7 +168,7 @@ static void nmbd_terminate(struct messaging_context *msg,
 static void expire_names_and_servers(time_t t)
 {
        static time_t lastrun = 0;
-  
+
        if ( !lastrun )
                lastrun = t;
        if ( t < (lastrun + 5) )
@@ -800,11 +800,11 @@ static bool open_sockets(bool isdaemon, int port)
        poptFreeContext(pc);
 
        global_in_nmbd = true;
-       
+
        StartupTime = time(NULL);
-       
+
        sys_srandom(time(NULL) ^ sys_getpid());
-       
+
        if (!override_logfile) {
                char *lfile = NULL;
                if (asprintf(&lfile, "%s/log.nmbd", get_dyn_LOGFILEBASE()) < 0) 
{
@@ -813,10 +813,10 @@ static bool open_sockets(bool isdaemon, int port)
                lp_set_logfile(lfile);
                SAFE_FREE(lfile);
        }
-       
+
        fault_setup();
        dump_core_setup("nmbd", lp_logfile());
-       
+
        /* POSIX demands that signals are inherited. If the invoking process has
         * these signals masked, we will have problems, as we won't receive 
them. */
        BlockSignals(False, SIGHUP);
@@ -882,7 +882,7 @@ static bool open_sockets(bool isdaemon, int port)
                DEBUG(0,("standard input is not a socket, assuming -D 
option\n"));
                is_daemon = True;
        }
-  
+
        if (is_daemon && !opt_interactive) {
                DEBUG( 2, ( "Becoming a daemon.\n" ) );
                become_daemon(Fork, no_process_group, log_stdout);
diff --git a/source3/printing/queue_process.c b/source3/printing/queue_process.c
index 5c00e8b..ce4047c 100644
--- a/source3/printing/queue_process.c
+++ b/source3/printing/queue_process.c
@@ -274,7 +274,7 @@ pid_t start_background_queue(struct tevent_context *ev,
                        exit(1);
                }
 
-               if (!serverid_register(procid_self(),
+               if (!serverid_register(messaging_server_id(msg_ctx),
                                       FLAG_MSG_GENERAL |
                                       FLAG_MSG_PRINT_GENERAL)) {
                        exit(1);
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index 31b6fca..cc51979 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -238,10 +238,11 @@ static void cleanup_timeout_fn(struct event_context 
*event_ctx,
                                void *private_data)
 {
        struct timed_event **cleanup_te = (struct timed_event **)private_data;
+       struct messaging_context *msg = smbd_messaging_context();
 
        DEBUG(1,("Cleaning up brl and lock database after unclean shutdown\n"));
-       message_send_all(smbd_messaging_context(), MSG_SMB_UNLOCK, NULL, 0, 
NULL);
-       messaging_send_buf(smbd_messaging_context(), procid_self(),
+       message_send_all(msg, MSG_SMB_UNLOCK, NULL, 0, NULL);
+       messaging_send_buf(msg, messaging_server_id(msg),
                                MSG_SMB_BRL_VALIDATE, NULL, 0);
        /* mark the cleanup as having been done */
        (*cleanup_te) = NULL;
@@ -273,8 +274,7 @@ static void remove_child_pid(struct tevent_context *ev_ctx,
                }
        }
 
-       child_id = procid_self(); /* Just initialize pid and potentially vnn */
-       child_id.pid = pid;
+       child_id = pid_to_procid(pid);
 
        if (!serverid_deregister(child_id)) {
                DEBUG(1, ("Could not remove pid %d from serverid.tdb\n",
@@ -476,7 +476,7 @@ static void smbd_accept_connection(struct tevent_context 
*ev,
                smbd_setup_sig_hup_handler(ev,
                                           msg_ctx);
 
-               if (!serverid_register(procid_self(),
+               if (!serverid_register(messaging_server_id(msg_ctx),
                                       FLAG_MSG_GENERAL|FLAG_MSG_SMBD
                                       |FLAG_MSG_DBWRAP
                                       |FLAG_MSG_PRINT_GENERAL)) {
@@ -736,7 +736,7 @@ static bool open_sockets_smbd(struct smbd_parent_context 
*parent,
           operations until it has gone thru a full startup, which
           includes checking to see that smbd is listening. */
 
-       if (!serverid_register(procid_self(),
+       if (!serverid_register(messaging_server_id(msg_ctx),
                               FLAG_MSG_GENERAL|FLAG_MSG_SMBD
                               |FLAG_MSG_PRINT_GENERAL
                               |FLAG_MSG_DBWRAP)) {


-- 
Samba Shared Repository

Reply via email to