The branch, master has been updated
       via  d65b17c3f7f s3:client:Use DEVICE_URI, instead of argv[0],for Device 
URI
      from  55b54e72174 s3: VFS: Remove vfs_netatalk. Old, unused and 
unmaintained.

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


- Log -----------------------------------------------------------------
commit d65b17c3f7f9959ed95b03cc09e020d7387b7931
Author: Bryan Mason <bma...@redhat.com>
Date:   Mon Sep 16 12:35:06 2019 -0700

    s3:client:Use DEVICE_URI, instead of argv[0],for Device URI
    
    CUPS sanitizes argv[0] by removing username/password, so use
    DEVICE_URI environment variable first.
    
    BUG: https://bugzilla.samba.org/show_bug.cgi?id=14128
    
    Signed-off-by: Bryan Mason <bma...@redhat.com>
    Reviewed-by: Alexander Bokovoy <a...@samba.org>
    Reviewed-by: Andreas Schneider <a...@samba.org>
    
    Autobuild-User(master): Andreas Schneider <a...@cryptomilk.org>
    Autobuild-Date(master): Wed Sep 18 12:31:11 UTC 2019 on sn-devel-184

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

Summary of changes:
 source3/client/smbspool.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/client/smbspool.c b/source3/client/smbspool.c
index ad988eb0df9..36f7f67ca94 100644
--- a/source3/client/smbspool.c
+++ b/source3/client/smbspool.c
@@ -256,13 +256,15 @@ main(int argc,                    /* I - Number of 
command-line arguments */
 
        /*
         * Find the URI ...
-        */
-       if (dev_uri == NULL) {
-               env = getenv("DEVICE_URI");
-               if (env != NULL && env[0] != '\0') {
-                       dev_uri = env;
-               }
-       }
+         *
+         * The URI in argv[0] is sanitized to remove username/password, so
+         * use DEVICE_URI if available. Otherwise keep the URI already
+         * discovered in argv.
+         */
+        env = getenv("DEVICE_URI");
+        if (env != NULL && env[0] != '\0') {
+          dev_uri = env;
+        }
 
        if (dev_uri == NULL) {
                fprintf(stderr,


-- 
Samba Shared Repository

Reply via email to