The branch, v3-4-test has been updated
       via  4996d89d19655ab6f0d4656ea72d6bad52ba7d6d (commit)
       via  d5bec253f7494dd74cce3acf59ddd417900e5ad3 (commit)
      from  24ff9b8dba8e4e0918b0aabf5cb8bacecfbc39d7 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-4-test


- Log -----------------------------------------------------------------
commit 4996d89d19655ab6f0d4656ea72d6bad52ba7d6d
Author: Volker Lendecke <[email protected]>
Date:   Fri Apr 3 10:43:13 2009 +0200

    Use cluster-aware procid_is_me instead of comparing pid's

commit d5bec253f7494dd74cce3acf59ddd417900e5ad3
Author: Volker Lendecke <[email protected]>
Date:   Fri Apr 3 10:42:43 2009 +0200

    Use procid_str in debug messages for better cluster-debuggability

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

Summary of changes:
 source3/locking/brlock.c |    4 ++--
 source3/smbd/oplock.c    |   28 +++++++++++++++-------------
 2 files changed, 17 insertions(+), 15 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/locking/brlock.c b/source3/locking/brlock.c
index aa522ac..be2948c 100644
--- a/source3/locking/brlock.c
+++ b/source3/locking/brlock.c
@@ -41,11 +41,11 @@ static struct db_context *brlock_db;
 
 static void print_lock_struct(unsigned int i, struct lock_struct *pls)
 {
-       DEBUG(10,("[%u]: smbpid = %u, tid = %u, pid = %u, ",
+       DEBUG(10,("[%u]: smbpid = %u, tid = %u, pid = %s, ",
                        i,
                        (unsigned int)pls->context.smbpid,
                        (unsigned int)pls->context.tid,
-                       (unsigned int)procid_to_pid(&pls->context.pid) ));
+                       procid_str(debug_ctx(), &pls->context.pid) ));
        
        DEBUG(10,("start = %.0f, size = %.0f, fnum = %d, %s %s\n",
                (double)pls->start,
diff --git a/source3/smbd/oplock.c b/source3/smbd/oplock.c
index 2287028..427eb5d 100644
--- a/source3/smbd/oplock.c
+++ b/source3/smbd/oplock.c
@@ -376,8 +376,9 @@ void process_oplock_async_level2_break_message(struct 
messaging_context *msg_ctx
        /* De-linearize incoming message. */
        message_to_share_mode_entry(&msg, (char *)data->data);
 
-       DEBUG(10, ("Got oplock async level 2 break message from pid %d: 
%s/%lu\n",
-                  (int)procid_to_pid(&src), file_id_string_tos(&msg.id), 
msg.share_file_id));
+       DEBUG(10, ("Got oplock async level 2 break message from pid %s: "
+                  "%s/%lu\n", procid_str(debug_ctx(), &src),
+                  file_id_string_tos(&msg.id), msg.share_file_id));
 
        fsp = initial_break_processing(msg.id, msg.share_file_id);
 
@@ -419,7 +420,7 @@ void process_oplock_async_level2_break_message(struct 
messaging_context *msg_ctx
        }
 
        /* Need to wait before sending a break message if we sent ourselves 
this message. */
-       if (procid_to_pid(&src) == sys_getpid()) {
+       if (procid_is_me(&src)) {
                wait_before_sending_break();
        }
 
@@ -472,8 +473,9 @@ static void process_oplock_break_message(struct 
messaging_context *msg_ctx,
        /* De-linearize incoming message. */
        message_to_share_mode_entry(&msg, (char *)data->data);
 
-       DEBUG(10, ("Got oplock break message from pid %d: %s/%lu\n",
-                  (int)procid_to_pid(&src), file_id_string_tos(&msg.id), 
msg.share_file_id));
+       DEBUG(10, ("Got oplock break message from pid %s: %s/%lu\n",
+                  procid_str(debug_ctx(), &src), file_id_string_tos(&msg.id),
+                  msg.share_file_id));
 
        fsp = initial_break_processing(msg.id, msg.share_file_id);
 
@@ -526,7 +528,7 @@ static void process_oplock_break_message(struct 
messaging_context *msg_ctx,
        }
 
        /* Need to wait before sending a break message if we sent ourselves 
this message. */
-       if (procid_to_pid(&src) == sys_getpid()) {
+       if (procid_is_me(&src)) {
                wait_before_sending_break();
        }
 
@@ -586,8 +588,8 @@ static void process_kernel_oplock_break(struct 
messaging_context *msg_ctx,
        pull_file_id_24((char *)data->data, &id);
        file_id = (unsigned long)IVAL(data->data, 24);
 
-       DEBUG(10, ("Got kernel oplock break message from pid %d: %s/%u\n",
-                  (int)procid_to_pid(&src), file_id_string_tos(&id),
+       DEBUG(10, ("Got kernel oplock break message from pid %s: %s/%u\n",
+                  procid_str(debug_ctx(), &src), file_id_string_tos(&id),
                   (unsigned int)file_id));
 
        fsp = initial_break_processing(id, file_id);
@@ -688,9 +690,9 @@ static void process_oplock_break_response(struct 
messaging_context *msg_ctx,
        /* De-linearize incoming message. */
        message_to_share_mode_entry(&msg, (char *)data->data);
 
-       DEBUG(10, ("Got oplock break response from pid %d: %s/%lu mid %u\n",
-                  (int)procid_to_pid(&src), file_id_string_tos(&msg.id), 
msg.share_file_id,
-                  (unsigned int)msg.op_mid));
+       DEBUG(10, ("Got oplock break response from pid %s: %s/%lu mid %u\n",
+                  procid_str(debug_ctx(), &src), file_id_string_tos(&msg.id),
+                  msg.share_file_id, (unsigned int)msg.op_mid));
 
        /* Here's the hack from open.c, store the mid in the 'port' field */
        schedule_deferred_open_smb_message(msg.op_mid);
@@ -717,8 +719,8 @@ static void process_open_retry_message(struct 
messaging_context *msg_ctx,
        /* De-linearize incoming message. */
        message_to_share_mode_entry(&msg, (char *)data->data);
 
-       DEBUG(10, ("Got open retry msg from pid %d: %s mid %u\n",
-                  (int)procid_to_pid(&src), file_id_string_tos(&msg.id),
+       DEBUG(10, ("Got open retry msg from pid %s: %s mid %u\n",
+                  procid_str(debug_ctx(), &src), file_id_string_tos(&msg.id),
                   (unsigned int)msg.op_mid));
 
        schedule_deferred_open_smb_message(msg.op_mid);


-- 
Samba Shared Repository

Reply via email to