diff options
author | Alexander Færøy <ahf@irssi.org> | 2014-07-07 22:26:04 +0200 |
---|---|---|
committer | Alexander Færøy <ahf@irssi.org> | 2014-07-07 22:26:04 +0200 |
commit | b2c3db4d5bc7bfa401b1e67ab24a115779012d93 (patch) | |
tree | 0e0e4ab57fcc52ee44ecaf8e1bb6d64fdb1d681b /src/core/misc.c | |
parent | 09a1801186bdc682f8d0e7ad8c049e7f93172665 (diff) | |
download | irssi-b2c3db4d5bc7bfa401b1e67ab24a115779012d93.zip |
Fix Clang warnings
This patch fixes a few warnings emitted by clang by removing the
initialization of the list by itself.
Diffstat (limited to 'src/core/misc.c')
-rw-r--r-- | src/core/misc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/misc.c b/src/core/misc.c index 32cfeb9b..5e6087cb 100644 --- a/src/core/misc.c +++ b/src/core/misc.c @@ -183,7 +183,7 @@ int strarray_find(char **array, const char *item) 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; 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) { - for (list = list; list != NULL; list = list->next) + for (; list != NULL; list = list->next) if (g_ascii_strcasecmp(list->data, key) == 0) return list; return NULL; @@ -268,7 +268,7 @@ GSList *hashtable_get_keys(GHashTable *hash) 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; 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) { - for (list = list; list != NULL; list = list->next) + for (; list != NULL; list = list->next) if (g_ascii_strcasecmp(list->data, key) == 0) return list; return NULL; |