From 9222a7b109bf5c20ac60466cfc293dc462989bdf Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Tue, 1 Jan 2008 18:22:26 +0100 Subject: Added group support for nicklist, fixed some bugs in plugins API and IRC plugin Added group support for nicklist (with subgroups). Partial changes in IRC protocol functions (new arguments with argv and argv_eol). Fixed some bugs: - nicklist in plugins API - problem in main loop with select() when SIGWINCH is received (terminal resize) - bug in string explode function - bug in infobar countdown. --- src/core/wee-string.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/core/wee-string.c') diff --git a/src/core/wee-string.c b/src/core/wee-string.c index 902d57764..22128117f 100644 --- a/src/core/wee-string.c +++ b/src/core/wee-string.c @@ -385,7 +385,7 @@ string_explode (char *string, char *separators, int keep_eol, i = 1; while ((ptr = strpbrk (ptr, separators))) { - while (strchr (separators, ptr[0]) != NULL) + while (ptr[0] && (strchr (separators, ptr[0]) != NULL)) ptr++; i++; } @@ -402,7 +402,7 @@ string_explode (char *string, char *separators, int keep_eol, for (i = 0; i < n_items; i++) { - while (strchr (separators, ptr1[0]) != NULL) + while (ptr1[0] && (strchr (separators, ptr1[0]) != NULL)) ptr1++; if (i == (n_items - 1) || (ptr2 = strpbrk (ptr1, separators)) == NULL) if ((ptr2 = strchr (ptr1, '\r')) == NULL) -- cgit v1.2.3