diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2004-05-14 13:07:20 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:53:45 -0500 |
commit | 53f2f8254b39b346c6ee718debd79bfc41207ec3 (patch) | |
tree | 1ee6fea7dfd0fa9ba9efe32b79d12afea288f338 /source4/lib/registry | |
parent | 85841414761ba20c43c71e4623f907fb5f8b18f4 (diff) | |
download | samba-53f2f8254b39b346c6ee718debd79bfc41207ec3.tar.gz samba-53f2f8254b39b346c6ee718debd79bfc41207ec3.tar.bz2 samba-53f2f8254b39b346c6ee718debd79bfc41207ec3.zip |
r734: Fix crash bug
(This used to be commit 178cd902fc7069e3d613c46fc4845101a0229655)
Diffstat (limited to 'source4/lib/registry')
-rw-r--r-- | source4/lib/registry/reg_backend_rpc/reg_backend_rpc.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/source4/lib/registry/reg_backend_rpc/reg_backend_rpc.c b/source4/lib/registry/reg_backend_rpc/reg_backend_rpc.c index c63ab20b82..af3a6ac214 100644 --- a/source4/lib/registry/reg_backend_rpc/reg_backend_rpc.c +++ b/source4/lib/registry/reg_backend_rpc/reg_backend_rpc.c @@ -316,14 +316,19 @@ static WERROR rpc_add_key(REG_KEY *parent, const char *name, uint32 access_mask, static WERROR rpc_query_key(REG_KEY *k) { NTSTATUS status; + WERROR error; struct winreg_QueryInfoKey r; struct rpc_data *mydata = k->handle->backend_data; - struct rpc_key_data *mykeydata; + struct rpc_key_data *mykeydata; + r.in.handle = &mykeydata->pol; init_winreg_String(&r.in.class, NULL); - + + error = rpc_key_put_rpc_data(k, &mykeydata); + if(!W_ERROR_IS_OK(error)) return error; + status = dcerpc_winreg_QueryInfoKey(mydata->pipe, k->mem_ctx, &r); - + if (!NT_STATUS_IS_OK(status)) { printf("QueryInfoKey failed - %s\n", nt_errstr(status)); return ntstatus_to_werror(status); |