diff options
author | Gerald Carter <jerry@samba.org> | 2007-05-03 20:52:48 +0000 |
---|---|---|
committer | Gerald Carter <jerry@samba.org> | 2007-05-03 20:52:48 +0000 |
commit | 0c7cbf0b4b65c20f633ad7f4db2fba9a6bcb040c (patch) | |
tree | 004b66ff1c290edee3cbb8506f242fc6a9904efa | |
parent | 812a6afc0a6a0d95ed7dc2a6e1847678143521f0 (diff) | |
download | samba-0c7cbf0b4b65c20f633ad7f4db2fba9a6bcb040c.tar.gz |
r22657: merge gd netsamlogon talloc fix
-rw-r--r-- | source/libsmb/samlogon_cache.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/source/libsmb/samlogon_cache.c b/source/libsmb/samlogon_cache.c index 0258f177382..c3ca9a3b15b 100644 --- a/source/libsmb/samlogon_cache.c +++ b/source/libsmb/samlogon_cache.c @@ -195,7 +195,6 @@ NET_USER_INFO_3* netsamlogon_cache_get( TALLOC_CTX *mem_ctx, const DOM_SID *user if ( data.dptr ) { - user = TALLOC_ZERO_P(mem_ctx, NET_USER_INFO_3); if (user == NULL) { return NULL; @@ -206,12 +205,12 @@ NET_USER_INFO_3* netsamlogon_cache_get( TALLOC_CTX *mem_ctx, const DOM_SID *user if ( !prs_uint32( "timestamp", &ps, 0, &t ) ) { prs_mem_free( &ps ); - SAFE_FREE(user); + TALLOC_FREE(user); return False; } if ( !net_io_user_info3("", user, &ps, 0, 3, 0) ) { - SAFE_FREE( user ); + TALLOC_FREE( user ); } prs_mem_free( &ps ); @@ -230,7 +229,7 @@ NET_USER_INFO_3* netsamlogon_cache_get( TALLOC_CTX *mem_ctx, const DOM_SID *user if ( (time_diff < 0 ) || (time_diff > lp_winbind_cache_time()) ) { DEBUG(10,("netsamlogon_cache_get: cache entry expired \n")); tdb_delete( netsamlogon_tdb, key ); - SAFE_FREE( user ); + TALLOC_FREE( user ); } #endif } |