summaryrefslogtreecommitdiff
path: root/src/core/wee-string.c
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2008-01-01 18:22:26 +0100
committerSebastien Helleu <flashcode@flashtux.org>2008-01-01 18:22:26 +0100
commit9222a7b109bf5c20ac60466cfc293dc462989bdf (patch)
treee9ddc3fb3cdc238083e1252deafb7f928b837192 /src/core/wee-string.c
parentcdbffe40da5f4fb23494b0464eea74ad1619a82b (diff)
downloadweechat-9222a7b109bf5c20ac60466cfc293dc462989bdf.zip
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.
Diffstat (limited to 'src/core/wee-string.c')
-rw-r--r--src/core/wee-string.c4
1 files changed, 2 insertions, 2 deletions
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)