From 7bdd7ecafad307028b51fc0f8fe361f7acb53b7d Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Thu, 29 Mar 2007 08:08:52 +0000 Subject: r22007: make string_tdb_data(NULL) possible... metze (This used to be commit d03094708378bde088bf6e90efe54deb83d3952e) --- source3/lib/util_tdb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source3') diff --git a/source3/lib/util_tdb.c b/source3/lib/util_tdb.c index 66ea929e81..5f96580120 100644 --- a/source3/lib/util_tdb.c +++ b/source3/lib/util_tdb.c @@ -53,12 +53,12 @@ TDB_DATA make_tdb_data(const char *dptr, size_t dsize) TDB_DATA string_tdb_data(const char *string) { - return make_tdb_data(string, strlen(string)); + return make_tdb_data(string, string ? strlen(string) : 0 ); } TDB_DATA string_term_tdb_data(const char *string) { - return make_tdb_data(string, strlen(string) + 1); + return make_tdb_data(string, string ? strlen(string) + 1 : 0); } /**************************************************************************** -- cgit