提交 09e9f281 编写于 作者: J Jiri Denemark

util: Non-existent string array does not contain any string

Make virStringArrayHasString return false when called on a non-existent
string array.
上级 bfc183c1
......@@ -172,6 +172,9 @@ virStringArrayHasString(char **strings, const char *needle)
{
size_t i = 0;
if (!strings)
return false;
while (strings[i]) {
if (STREQ(strings[i++], needle))
return true;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册