The branch, v4-4-test has been updated
       via  e4e5018 ctdb-protocol: Fix marshalling for GET_DB_SEQNUM control 
request
       via  80e17c7 s3/smbd: in call_trans2qfilepathinfo call lstat when 
dealing with posix pathnames
       via  44107d9 ctdb-packaging: Fix systemd network dependency
      from  87a42e6 ctdb-daemon: Don't steal control structure before 
synchronous reply

https://git.samba.org/?p=samba.git;a=shortlog;h=v4-4-test


- Log -----------------------------------------------------------------
commit e4e50182d886f68f9dcea90e4eed22b6feb23b06
Author: Amitay Isaacs <ami...@gmail.com>
Date:   Tue Sep 13 16:05:14 2016 +1000

    ctdb-protocol: Fix marshalling for GET_DB_SEQNUM control request
    
    BUG: https://bugzilla.samba.org/show_bug.cgi?id=12259
    
    Even though database id is 32-bit, it's sent on wire as 64-bits.
    The database id is the first 32-bits on the wire.  This needs fixing
    eventually, but for now keep the same wire format.
    
    Signed-off-by: Amitay Isaacs <ami...@gmail.com>
    Reviewed-by: Martin Schwenke <mar...@meltin.net>
    (cherry picked from commit bdff6255af113827340adc3da609e127503d9ba5)
    
    Autobuild-User(v4-4-test): Karolin Seeger <ksee...@samba.org>
    Autobuild-Date(v4-4-test): Fri Sep 16 12:39:00 CEST 2016 on sn-devel-144

commit 80e17c7c15413af1b9b0895979bd965d1f5bfa65
Author: Ralph Boehme <s...@samba.org>
Date:   Sun Sep 11 15:35:37 2016 +0200

    s3/smbd: in call_trans2qfilepathinfo call lstat when dealing with posix 
pathnames
    
    This might be an info level SMB_INFO_QUERY_ALL_EAS which is not covered
    by INFO_LEVEL_IS_UNIX(). If smb_fname is a symlink we would then stat it
    in POSIX context.
    
    Bug: https://bugzilla.samba.org/show_bug.cgi?id=12256
    
    Signed-off-by: Ralph Boehme <s...@samba.org>
    Reviewed-by: Jeremy Allison <j...@samba.org>
    (cherry picked from commit b13b3c11054f918f18841186a6efc5dedd2ffd66)

commit 44107d9d228617dedabbf0bd0961a82f4e88d078
Author: Martin Schwenke <mar...@meltin.net>
Date:   Thu Sep 8 12:28:00 2016 +1000

    ctdb-packaging: Fix systemd network dependency
    
    https://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/ says:
    
      network.target has very little meaning during start-up. [...]
      Whether any network interfaces are already configured when it is
      reached is undefined. [...]
    
      network-online.target is a target that actively waits until the
      ne[t]work is "up",
    
    CTDB expects to be able to bind a socket to a node address and expects
    interfaces for public IP addresses to exist.  CTDB also doesn't expect
    time to jump, so also wait until time is synchronised.
    
    BUG: https://bugzilla.samba.org/show_bug.cgi?id=12255
    
    Signed-off-by: Martin Schwenke <mar...@meltin.net>
    Reviewed-by: Steve French <sfre...@samba.org>
    Reviewed-by: Amitay Isaacs <ami...@gmail.com>
    Tested-by: Steve French <sfre...@samba.org>
    (cherry picked from commit 35dcaadc8ebc9ec80e04f1d2eee694ebc6914a31)

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

Summary of changes:
 ctdb/config/ctdb.service         |  2 +-
 ctdb/protocol/protocol_control.c | 14 ++++----------
 source3/smbd/trans2.c            |  7 ++++---
 3 files changed, 9 insertions(+), 14 deletions(-)


Changeset truncated at 500 lines:

diff --git a/ctdb/config/ctdb.service b/ctdb/config/ctdb.service
index ea37c30..63cdfa9 100644
--- a/ctdb/config/ctdb.service
+++ b/ctdb/config/ctdb.service
@@ -1,6 +1,6 @@
 [Unit]
 Description=CTDB
-After=network.target
+After=network-online.target time-sync.target
 
 [Service]
 Type=forking
diff --git a/ctdb/protocol/protocol_control.c b/ctdb/protocol/protocol_control.c
index e7487da..3a51b65 100644
--- a/ctdb/protocol/protocol_control.c
+++ b/ctdb/protocol/protocol_control.c
@@ -49,7 +49,6 @@ struct ctdb_reply_control_wire {
 static size_t ctdb_req_control_data_len(struct ctdb_req_control_data *cd)
 {
        size_t len = 0;
-       uint64_t u64;
 
        if (cd == NULL) {
                return 0;
@@ -384,8 +383,7 @@ static size_t ctdb_req_control_data_len(struct 
ctdb_req_control_data *cd)
                break;
 
        case CTDB_CONTROL_GET_DB_SEQNUM:
-               u64 = cd->data.db_id;
-               len = ctdb_uint64_len(u64);
+               len = ctdb_uint64_len((uint64_t)cd->data.db_id);
                break;
 
        case CTDB_CONTROL_DB_SET_HEALTHY:
@@ -501,8 +499,6 @@ static size_t ctdb_req_control_data_len(struct 
ctdb_req_control_data *cd)
 static void ctdb_req_control_data_push(struct ctdb_req_control_data *cd,
                                       uint8_t *buf)
 {
-       uint64_t u64;
-
        switch (cd->opcode) {
        case CTDB_CONTROL_PROCESS_EXISTS:
                ctdb_pid_push(cd->data.pid, buf);
@@ -724,8 +720,7 @@ static void ctdb_req_control_data_push(struct 
ctdb_req_control_data *cd,
                break;
 
        case CTDB_CONTROL_GET_DB_SEQNUM:
-               u64 = cd->data.db_id;
-               ctdb_uint64_push(u64, buf);
+               ctdb_uint32_push(cd->data.db_id, buf);
                break;
 
        case CTDB_CONTROL_DB_SET_HEALTHY:
@@ -824,7 +819,6 @@ static int ctdb_req_control_data_pull(uint8_t *buf, size_t 
buflen,
                                      struct ctdb_req_control_data *cd)
 {
        int ret = 0;
-       uint64_t u64 = 0;
 
        cd->opcode = opcode;
 
@@ -1103,8 +1097,8 @@ static int ctdb_req_control_data_pull(uint8_t *buf, 
size_t buflen,
                break;
 
        case CTDB_CONTROL_GET_DB_SEQNUM:
-               ret = ctdb_uint64_pull(buf, buflen, mem_ctx, &u64);
-               cd->data.db_id = (uint32_t)u64;
+               ret = ctdb_uint32_pull(buf, buflen, mem_ctx,
+                                      &cd->data.db_id);
                break;
 
        case CTDB_CONTROL_DB_SET_HEALTHY:
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c
index 09392a3..e3de61e 100644
--- a/source3/smbd/trans2.c
+++ b/source3/smbd/trans2.c
@@ -5700,7 +5700,8 @@ static void call_trans2qfilepathinfo(connection_struct 
*conn,
                        }
                        if (info_level == SMB_QUERY_FILE_UNIX_BASIC ||
                                        info_level == SMB_QUERY_FILE_UNIX_INFO2 
||
-                                       info_level == SMB_QUERY_FILE_UNIX_LINK) 
{
+                                       info_level == SMB_QUERY_FILE_UNIX_LINK 
||
+                                       req->posix_pathnames) {
                                ucf_flags |= UCF_UNIX_NAME_LOOKUP;
                        }
                }
@@ -5761,7 +5762,7 @@ static void call_trans2qfilepathinfo(connection_struct 
*conn,
                                return;
                        }
 
-                       if (INFO_LEVEL_IS_UNIX(info_level)) {
+                       if (INFO_LEVEL_IS_UNIX(info_level) || 
req->posix_pathnames) {
                                /* Always do lstat for UNIX calls. */
                                if (SMB_VFS_LSTAT(conn, smb_fname_base) != 0) {
                                        DEBUG(3,("call_trans2qfilepathinfo: "
@@ -5807,7 +5808,7 @@ static void call_trans2qfilepathinfo(connection_struct 
*conn,
                        }
                }
 
-               if (INFO_LEVEL_IS_UNIX(info_level)) {
+               if (INFO_LEVEL_IS_UNIX(info_level) || req->posix_pathnames) {
                        /* Always do lstat for UNIX calls. */
                        if (SMB_VFS_LSTAT(conn, smb_fname)) {
                                DEBUG(3,("call_trans2qfilepathinfo: "


-- 
Samba Shared Repository

Reply via email to