1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00

r22007: make string_tdb_data(NULL) possible...

metze
(This used to be commit d03094708378bde088bf6e90efe54deb83d3952e)
This commit is contained in:
Stefan Metzmacher 2007-03-29 08:08:52 +00:00 committed by Gerald (Jerry) Carter
parent e8265c6515
commit 7bdd7ecafa

View File

@ -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);
}
/****************************************************************************