summaryrefslogtreecommitdiff
path: root/source3/utils/net_rpc.c
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2012-12-10 17:36:39 +0100
committerGünther Deschner <gd@samba.org>2012-12-12 09:42:32 +0100
commite4e3293b482d48bc6a503e1280fe2a20556548ef (patch)
tree22153f1c75487e36d46379f3f14abeedbcdc6479 /source3/utils/net_rpc.c
parentf70c56b74769711e358860655bbb5c2329ad005b (diff)
downloadsamba-e4e3293b482d48bc6a503e1280fe2a20556548ef.tar.gz
samba-e4e3293b482d48bc6a503e1280fe2a20556548ef.tar.bz2
samba-e4e3293b482d48bc6a503e1280fe2a20556548ef.zip
s3-net: Check the return value of strlower_m().
Found by Coverity. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
Diffstat (limited to 'source3/utils/net_rpc.c')
-rw-r--r--source3/utils/net_rpc.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c
index 2ccc92876b..c112a15e76 100644
--- a/source3/utils/net_rpc.c
+++ b/source3/utils/net_rpc.c
@@ -369,7 +369,9 @@ static NTSTATUS rpc_oldjoin_internals(struct net_context *c,
}
fstrcpy(trust_passwd, lp_netbios_name());
- strlower_m(trust_passwd);
+ if (!strlower_m(trust_passwd)) {
+ return NT_STATUS_UNSUCCESSFUL;
+ }
/*
* Machine names can be 15 characters, but the max length on