svn commit: samba r19973 - in
branches/SAMBA_3_0_24/source/nsswitch: .
jra at samba.org
jra at samba.org
Thu Nov 30 23:49:28 GMT 2006
Author: jra
Date: 2006-11-30 23:49:27 +0000 (Thu, 30 Nov 2006)
New Revision: 19973
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=19973
Log:
Make SEQNUM store symmetrical w.r.t. fetch - use
tdb_store_bystring / tdb_fetch_bystring. This shouldn't
affect any tdb cache files but removes one possible error.
Jeremy.
Modified:
branches/SAMBA_3_0_24/source/nsswitch/winbindd_cache.c
Changeset:
Modified: branches/SAMBA_3_0_24/source/nsswitch/winbindd_cache.c
===================================================================
--- branches/SAMBA_3_0_24/source/nsswitch/winbindd_cache.c 2006-11-30 20:29:49 UTC (rev 19972)
+++ branches/SAMBA_3_0_24/source/nsswitch/winbindd_cache.c 2006-11-30 23:49:27 UTC (rev 19973)
@@ -372,7 +372,7 @@
static NTSTATUS store_cache_seqnum( struct winbindd_domain *domain )
{
- TDB_DATA data, key;
+ TDB_DATA data;
fstring key_str;
char buf[8];
@@ -382,15 +382,13 @@
}
fstr_sprintf( key_str, "SEQNUM/%s", domain->name );
- key.dptr = key_str;
- key.dsize = strlen(key_str)+1;
SIVAL(buf, 0, domain->sequence_number);
SIVAL(buf, 4, domain->last_seq_check);
data.dptr = buf;
data.dsize = 8;
- if ( tdb_store( wcache->tdb, key, data, TDB_REPLACE) == -1 ) {
+ if ( tdb_store_bystring( wcache->tdb, key_str, data, TDB_REPLACE) == -1 ) {
DEBUG(10,("store_cache_seqnum: tdb_store fail key [%s]\n", key_str ));
return NT_STATUS_UNSUCCESSFUL;
}
More information about the samba-cvs
mailing list