diff options
author | Volker Lendecke <vl@samba.org> | 2008-04-07 10:19:25 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2008-04-07 10:20:39 +0200 |
commit | 768a5a23e001411d26fc293624b9ab2002a90b65 (patch) | |
tree | 3d37241024bdc4fdfdf46c26b76bf714050e6d21 /source3 | |
parent | aa41d74843dd6532c300da682472787759b6d82d (diff) | |
download | samba-768a5a23e001411d26fc293624b9ab2002a90b65.tar.gz samba-768a5a23e001411d26fc293624b9ab2002a90b65.tar.bz2 samba-768a5a23e001411d26fc293624b9ab2002a90b65.zip |
Fix bug 5375
Thanks to Moskvin for testing
(This used to be commit d3c31aa36c451f0a19496cd33c0b055b466e6b09)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/lib/util_str.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c index cb8a100fa7..6310e2464d 100644 --- a/source3/lib/util_str.c +++ b/source3/lib/util_str.c @@ -1972,25 +1972,26 @@ int str_list_count( const char **list ) } /****************************************************************************** - version of standard_sub_basic() for string lists; uses alloc_sub_basic() + version of standard_sub_basic() for string lists; uses talloc_sub_basic() for the work *****************************************************************************/ bool str_list_sub_basic( char **list, const char *smb_name, const char *domain_name ) { + TALLOC_CTX *ctx = list; char *s, *tmpstr; while ( *list ) { s = *list; - tmpstr = alloc_sub_basic(smb_name, domain_name, s); + tmpstr = talloc_sub_basic(ctx, smb_name, domain_name, s); if ( !tmpstr ) { DEBUG(0,("str_list_sub_basic: " "alloc_sub_basic() return NULL!\n")); return false; } - SAFE_FREE(*list); + TALLOC_FREE(*list); *list = tmpstr; list++; |