git.samba.org
/
metze
/
samba
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1a22e97
)
Fix a crash in _winreg_QueryValue
author
Volker Lendecke
<vl@samba.org>
Fri, 13 Jun 2008 13:30:08 +0000
(15:30 +0200)
committer
Volker Lendecke
<vl@samba.org>
Fri, 13 Jun 2008 13:33:24 +0000
(15:33 +0200)
Coverity ID 474, value_length and type are both unique, not ref pointers and
can thus be NULL.
Karolin, please merge this to -stable.
Thanks,
Volker
source/rpc_server/srv_winreg_nt.c
patch
|
blob
|
history
diff --git
a/source/rpc_server/srv_winreg_nt.c
b/source/rpc_server/srv_winreg_nt.c
index 7b7487110481fab7abe4a6f0ada2a78307722a4b..84bcf0bf8921952682859123fb876828f25c2206 100644
(file)
--- a/
source/rpc_server/srv_winreg_nt.c
+++ b/
source/rpc_server/srv_winreg_nt.c
@@
-230,6
+230,10
@@
WERROR _winreg_QueryValue(pipes_struct *p, struct winreg_QueryValue *r)
if ( !regkey )
return WERR_BADFID;
+ if ((r->out.value_length == NULL) || (r->out.type == NULL)) {
+ return WERR_INVALID_PARAM;
+ }
+
*r->out.value_length = *r->out.type = REG_NONE;
DEBUG(7,("_reg_info: policy key name = [%s]\n", regkey->key->name));