summaryrefslogtreecommitdiff
path: root/source3/tdb/tdb.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2002-11-07 02:15:35 +0000
committerJeremy Allison <jra@samba.org>2002-11-07 02:15:35 +0000
commit93042487882d8b2407541ad21d2e9bc2b59142e5 (patch)
tree9c71fc306cbf8088c23c04c3d0bf46182b32637d /source3/tdb/tdb.c
parent3955716f90c317684093b43065c73167382137d4 (diff)
downloadsamba-93042487882d8b2407541ad21d2e9bc2b59142e5.tar.gz
samba-93042487882d8b2407541ad21d2e9bc2b59142e5.tar.bz2
samba-93042487882d8b2407541ad21d2e9bc2b59142e5.zip
Merge of scalable printing code fix... Needs testing.
Jeremy. (This used to be commit d030df76439c72825d68410211e62090438cef54)
Diffstat (limited to 'source3/tdb/tdb.c')
-rw-r--r--source3/tdb/tdb.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/tdb/tdb.c b/source3/tdb/tdb.c
index c57d23cb6f..2a6dca16a8 100644
--- a/source3/tdb/tdb.c
+++ b/source3/tdb/tdb.c
@@ -1442,7 +1442,8 @@ int tdb_store(TDB_CONTEXT *tdb, TDB_DATA key, TDB_DATA dbuf, int flag)
}
memcpy(p, key.dptr, key.dsize);
- memcpy(p+key.dsize, dbuf.dptr, dbuf.dsize);
+ if (dbuf.dsize)
+ memcpy(p+key.dsize, dbuf.dptr, dbuf.dsize);
/* now we're into insert / modify / replace of a record which
* we know could not be optimised by an in-place store (for