1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-15 05:57:49 +03:00

tdbtool: fix off-by-one error in argument length. (bug #2344)

This prevented all commands operating on keys (all non-traverse commands)
in tdbtool to fail with a "fetch failed" or "delete failed" message.

It seems that it fixes bug #2344 ...

Apparently this bug was introduced with 94e53472666ed in 2005.
Either nobody is using tdbtool or else tdb_find() has become
more strict about the key legth in the meantime. :-)

Michael
(This used to be commit fafb8ad2b81b9a46cf8259bedc1dca5023b06115)
This commit is contained in:
Michael Adam 2008-07-08 15:33:36 +02:00
parent 2cb149b0b3
commit 6ae40a8b74

View File

@ -598,7 +598,7 @@ static char *convert_string(char *instring, size_t *sizep)
}
length++;
}
*sizep = length;
*sizep = length + 1;
return instring;
}