diff options
author | Volker Lendecke <vlendec@samba.org> | 2006-11-20 18:51:00 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:15:57 -0500 |
commit | ef012f8e7a296a99786e568f844c0aef53bc673d (patch) | |
tree | de3921e7b59ce89e4e00f381e0f5797e2bda14d2 /source3 | |
parent | ded7c032a311afdda225bde70a9cb0581cd7ee48 (diff) | |
download | samba-ef012f8e7a296a99786e568f844c0aef53bc673d.tar.gz samba-ef012f8e7a296a99786e568f844c0aef53bc673d.tar.bz2 samba-ef012f8e7a296a99786e568f844c0aef53bc673d.zip |
r19804: Fix a valgrind error
(This used to be commit cb9e16c8389f25f487e627bbeb06ec45f25aef6b)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/utils/net_rpc_registry.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/source3/utils/net_rpc_registry.c b/source3/utils/net_rpc_registry.c index 776a49f99c..9bcf1ce244 100644 --- a/source3/utils/net_rpc_registry.c +++ b/source3/utils/net_rpc_registry.c @@ -156,8 +156,7 @@ static NTSTATUS rpc_registry_enumerate_internal(const DOM_SID *domain_sid, struct winreg_StringBuf class_namebuf; struct winreg_StringBuf *p_class_namebuf = &class_namebuf; fstring kname; - NTTIME modtime; - NTTIME *p_modtime = &modtime; + NTTIME *modtime = NULL; class_namebuf.name = NULL; class_namebuf.size = 0; @@ -172,7 +171,7 @@ static NTSTATUS rpc_registry_enumerate_internal(const DOM_SID *domain_sid, status = rpccli_winreg_EnumKey(pipe_hnd, mem_ctx, &pol_key, idx, &subkey_namebuf, - &p_class_namebuf, &p_modtime); + &p_class_namebuf, &modtime); if ( W_ERROR_EQUAL(ntstatus_to_werror(status), WERR_NO_MORE_ITEMS) ) { status = NT_STATUS_OK; @@ -185,8 +184,8 @@ static NTSTATUS rpc_registry_enumerate_internal(const DOM_SID *domain_sid, StrnCpy( kname, subkey_namebuf.name, MIN(subkey_namebuf.length,sizeof(kname))-1 ); kname[MIN(subkey_namebuf.length,sizeof(kname))-1] = '\0'; d_printf("Keyname = %s\n", kname); - d_printf("Modtime = %s\n", - http_timestring(nt_time_to_unix(modtime)) ); + d_printf("Modtime = %s\n", modtime + ? http_timestring(nt_time_to_unix(*modtime)):"None"); d_printf("\n" ); idx++; |