ctdb-tests: Avoid warning about NULL dereference
authorMartin Schwenke <martin@meltin.net>
Fri, 21 Jun 2019 06:08:58 +0000 (16:08 +1000)
committerAmitay Isaacs <amitay@samba.org>
Fri, 5 Jul 2019 05:03:23 +0000 (05:03 +0000)
commit75747c6106fa2a966686f7a523cdb9d28708b870
treeed28cfa28846f970d8e70f93ae96c3f119561e0b
parentd855dc2a5faff1eafec287fa8748000d21949684
ctdb-tests: Avoid warning about NULL dereference

Static analysis finds that earlier in the call path, ctdb_string_len()
checks for NULL, so complains that a NULL value can be passed to
strlen() here.  Avoid this by adding an assert().

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/tests/src/protocol_types_compat_test.c