s3-utils/smbcacls.c: replace cli_query_secdesc_old()
authorBjörn Baumbach <bb@sernet.de>
Fri, 22 Jul 2011 14:56:04 +0000 (16:56 +0200)
committerStefan Metzmacher <metze@samba.org>
Sat, 23 Jul 2011 07:31:02 +0000 (09:31 +0200)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
source3/utils/smbcacls.c

index 618314676234ced33adfc08a26ef08ecd0e8fae9..18f76c47239219ab372e02b211e38543b03f2169 100644 (file)
@@ -722,12 +722,13 @@ static struct security_descriptor *get_secdesc(struct cli_state *cli, const char
                return NULL;
        }
 
                return NULL;
        }
 
-       sd = cli_query_secdesc_old(cli, fnum, talloc_tos());
+       status = cli_query_secdesc(cli, fnum, talloc_tos(), &sd);
 
        cli_close(cli, fnum);
 
 
        cli_close(cli, fnum);
 
-       if (!sd) {
-               printf("Failed to get security descriptor\n");
+       if (!NT_STATUS_IS_OK(status)) {
+               printf("Failed to get security descriptor: %s\n",
+                      nt_errstr(status));
                return NULL;
        }
         return sd;
                return NULL;
        }
         return sd;