From: Stefan Metzmacher Date: Mon, 21 May 2007 13:40:27 +0000 (+0000) Subject: r23039: merge from SAMBA_3_0_26: X-Git-Tag: samba-4.0.0alpha6~801^2~5823 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=5057c595d5637ad610c54de0300488ca690f1438;p=thirdparty%2Fsamba.git r23039: merge from SAMBA_3_0_26: use a helper function to construct the TDB_DATA key as strlen_m() is totally wrong here anyway metze (This used to be commit fb77cc7fbc0100c66365109ae6c3cc4824079a2e) --- diff --git a/source3/nsswitch/winbindd_cache.c b/source3/nsswitch/winbindd_cache.c index 28a0a094228..aa38bb69713 100644 --- a/source3/nsswitch/winbindd_cache.c +++ b/source3/nsswitch/winbindd_cache.c @@ -3566,8 +3566,7 @@ static TDB_DATA make_tdc_key( const char *domain_name ) asprintf( &keystr, "TRUSTDOMCACHE/%s", domain_name ); - key.dptr = (unsigned char*)keystr; - key.dsize = strlen_m(keystr) + 1; + key = string_term_tdb_data(keystr); return key; }