summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2006-11-22 16:39:07 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:16:01 -0500
commitca70f53930df64b6a2fcb563b4ffa84d99a01741 (patch)
treecf35df758cb3693645d3752b7fa1962e5e949f17 /source3/utils
parent9e29e5d2b893be02786b15495c71b4e0b09ec953 (diff)
downloadsamba-ca70f53930df64b6a2fcb563b4ffa84d99a01741.tar.gz
samba-ca70f53930df64b6a2fcb563b4ffa84d99a01741.tar.bz2
samba-ca70f53930df64b6a2fcb563b4ffa84d99a01741.zip
r19840: Fix an uninitialized variable
(This used to be commit c4b5e8c7a0b936a3d95f221718a048d5374e836a)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/net_sam.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source3/utils/net_sam.c b/source3/utils/net_sam.c
index b041bd7a65..d92bf1521c 100644
--- a/source3/utils/net_sam.c
+++ b/source3/utils/net_sam.c
@@ -378,6 +378,13 @@ static int net_sam_policy_set(int argc, const char **argv)
printf("Account policy \"%s\" description: %s\n", account_policy,
account_policy_get_desc(field));
+
+ if (!pdb_get_account_policy(field, &old_value)) {
+ fprintf(stderr, "Valid account policy, but unable to "
+ "fetch value!\n");
+ return -1;
+ }
+
printf("Account policy \"%s\" value was: %d\n", account_policy,
old_value);