diff options
author | Volker Lendecke <vl@samba.org> | 2011-04-21 22:09:27 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2011-04-22 10:06:33 +0200 |
commit | 7e7ad53cbd77ce2201fd46bd2c08a601725f9f5b (patch) | |
tree | 75f330904cd9b03eb54a75513e41e38834f1cd45 | |
parent | e919e767fb846fc91160cf44cbc838a9b4f2a832 (diff) | |
download | samba-7e7ad53cbd77ce2201fd46bd2c08a601725f9f5b.tar.gz samba-7e7ad53cbd77ce2201fd46bd2c08a601725f9f5b.tar.xz samba-7e7ad53cbd77ce2201fd46bd2c08a601725f9f5b.zip |
s3: Fix Coverity ID 1340, NULL_RETURNS
-rw-r--r-- | source3/lib/smbconf/smbconf_reg.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/lib/smbconf/smbconf_reg.c b/source3/lib/smbconf/smbconf_reg.c index adac233732..67df03cbd2 100644 --- a/source3/lib/smbconf/smbconf_reg.c +++ b/source3/lib/smbconf/smbconf_reg.c @@ -714,6 +714,10 @@ static WERROR smbconf_reg_drop(struct smbconf_ctx *ctx) goto done; } p = strrchr(path, '\\'); + if (p == NULL) { + werr = WERR_INVALID_PARAM; + goto done; + } *p = '\0'; werr = reg_open_path(mem_ctx, path, REG_KEY_WRITE, token, &parent_key); |