diff options
author | Stefan Metzmacher <metze@samba.org> | 2007-03-29 08:24:15 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:19:00 -0500 |
commit | b9461058d59f8e4f4b69c31592bd12a179b2d8ac (patch) | |
tree | 45009d3dba562e32a2f899d524c841a849b25370 /source3 | |
parent | 7bdd7ecafad307028b51fc0f8fe361f7acb53b7d (diff) | |
download | samba-b9461058d59f8e4f4b69c31592bd12a179b2d8ac.tar.gz samba-b9461058d59f8e4f4b69c31592bd12a179b2d8ac.tar.bz2 samba-b9461058d59f8e4f4b69c31592bd12a179b2d8ac.zip |
r22008: use string_term_tdb_data()
metze
(This used to be commit 1f047d7e31252481c4ed905e0dfdb791c704adca)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/connection.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/source3/smbd/connection.c b/source3/smbd/connection.c index 0442a9441a..7838c5c23d 100644 --- a/source3/smbd/connection.c +++ b/source3/smbd/connection.c @@ -272,11 +272,10 @@ static TDB_DATA* make_pipe_rec_key( struct pipe_open_rec *prec ) snprintf( key_string, sizeof(key_string), "%s/%d/%d", prec->name, procid_to_pid(&prec->pid), prec->pnum ); - if ( (kbuf->dptr = talloc_strdup(prec, key_string)) == NULL ) + *kbuf = string_term_tdb_data(talloc_strdup(prec, key_string)); + if (kbuf->dptr == NULL ) return NULL; - - kbuf->dsize = strlen(key_string)+1; - + return kbuf; } |