svn commit: samba r18732 - in branches/SAMBA_3_0/source/rpcclient: .

gd at samba.org gd at samba.org
Wed Sep 20 18:44:24 GMT 2006


Author: gd
Date: 2006-09-20 18:44:23 +0000 (Wed, 20 Sep 2006)
New Revision: 18732

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18732

Log:
Fix build warning as pointed out by Volker.

Guenther

Modified:
   branches/SAMBA_3_0/source/rpcclient/cmd_samr.c


Changeset:
Modified: branches/SAMBA_3_0/source/rpcclient/cmd_samr.c
===================================================================
--- branches/SAMBA_3_0/source/rpcclient/cmd_samr.c	2006-09-20 18:15:46 UTC (rev 18731)
+++ branches/SAMBA_3_0/source/rpcclient/cmd_samr.c	2006-09-20 18:44:23 UTC (rev 18732)
@@ -1373,18 +1373,14 @@
 	uint32 access_mask = MAXIMUM_ALLOWED_ACCESS;
 	uint16 info_level = 1;
 	uint32 idx;
-	const char *name;
 
-	if (argc > 6) {
+	if (argc < 2 || argc > 3) {
 		printf("Usage: %s mame [info level]\n", argv[0]);
 		return NT_STATUS_OK;
 	}
 
-	if (argc >= 2)
-                name = argv[1];
-
 	if (argc >= 3)
-                sscanf(argv[2], "%hd", &info_level);
+		sscanf(argv[2], "%hd", &info_level);
         
 
 	/* Get sam policy handle */
@@ -1407,7 +1403,7 @@
 	/* Query display info index */
 
 	result = rpccli_samr_get_dispenum_index(cli, mem_ctx, &domain_pol,
-						info_level, name, &idx);
+						info_level, argv[1], &idx);
 	if (!NT_STATUS_IS_OK(result)) {
 		goto done;
 	};



More information about the samba-cvs mailing list