mirror of
https://github.com/irssi/irssi.git
synced 2025-02-02 15:08:01 -05:00
Fix Clang warnings
This patch fixes a few warnings emitted by clang by removing the initialization of the list by itself.
This commit is contained in:
parent
09a1801186
commit
b2c3db4d5b
@ -183,7 +183,7 @@ int strarray_find(char **array, const char *item)
|
|||||||
|
|
||||||
GSList *gslist_find_string(GSList *list, const char *key)
|
GSList *gslist_find_string(GSList *list, const char *key)
|
||||||
{
|
{
|
||||||
for (list = list; list != NULL; list = list->next)
|
for (; list != NULL; list = list->next)
|
||||||
if (strcmp(list->data, key) == 0) return list;
|
if (strcmp(list->data, key) == 0) return list;
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
@ -191,7 +191,7 @@ GSList *gslist_find_string(GSList *list, const char *key)
|
|||||||
|
|
||||||
GSList *gslist_find_icase_string(GSList *list, const char *key)
|
GSList *gslist_find_icase_string(GSList *list, const char *key)
|
||||||
{
|
{
|
||||||
for (list = list; list != NULL; list = list->next)
|
for (; list != NULL; list = list->next)
|
||||||
if (g_ascii_strcasecmp(list->data, key) == 0) return list;
|
if (g_ascii_strcasecmp(list->data, key) == 0) return list;
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
@ -268,7 +268,7 @@ GSList *hashtable_get_keys(GHashTable *hash)
|
|||||||
|
|
||||||
GList *glist_find_string(GList *list, const char *key)
|
GList *glist_find_string(GList *list, const char *key)
|
||||||
{
|
{
|
||||||
for (list = list; list != NULL; list = list->next)
|
for (; list != NULL; list = list->next)
|
||||||
if (strcmp(list->data, key) == 0) return list;
|
if (strcmp(list->data, key) == 0) return list;
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
@ -276,7 +276,7 @@ GList *glist_find_string(GList *list, const char *key)
|
|||||||
|
|
||||||
GList *glist_find_icase_string(GList *list, const char *key)
|
GList *glist_find_icase_string(GList *list, const char *key)
|
||||||
{
|
{
|
||||||
for (list = list; list != NULL; list = list->next)
|
for (; list != NULL; list = list->next)
|
||||||
if (g_ascii_strcasecmp(list->data, key) == 0) return list;
|
if (g_ascii_strcasecmp(list->data, key) == 0) return list;
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
Loading…
Reference in New Issue
Block a user