mirror of
https://github.com/irssi/irssi.git
synced 2026-08-08 19:30:15 +02:00
Merge pull request #440 from vague666/strarray_find_bugfix
Return -1 from null-test to comply with the rest of strarray_find
This commit is contained in:
commit
6aa33c4aae
1 changed files with 2 additions and 2 deletions
|
|
@ -169,8 +169,8 @@ int strarray_find(char **array, const char *item)
|
|||
char **tmp;
|
||||
int index;
|
||||
|
||||
g_return_val_if_fail(array != NULL, 0);
|
||||
g_return_val_if_fail(item != NULL, 0);
|
||||
g_return_val_if_fail(array != NULL, -1);
|
||||
g_return_val_if_fail(item != NULL, -1);
|
||||
|
||||
index = 0;
|
||||
for (tmp = array; *tmp != NULL; tmp++, index++) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue