Dolda2000 GitWeb
/
doldaconnect.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b0d389a
)
Bugfixes in the old-style hublist decoder.
author
Fredrik Tolf
<fredrik@dolda2000.com>
Sun, 22 Jul 2007 04:21:57 +0000
(06:21 +0200)
committer
Fredrik Tolf
<fredrik@dolda2000.com>
Sun, 22 Jul 2007 04:21:57 +0000
(06:21 +0200)
clients/gtk2/hublist-old.c
patch
|
blob
|
blame
|
history
diff --git
a/clients/gtk2/hublist-old.c
b/clients/gtk2/hublist-old.c
index
83da7fc
..
ddc00cb
100644
(file)
--- a/
clients/gtk2/hublist-old.c
+++ b/
clients/gtk2/hublist-old.c
@@
-45,10
+45,10
@@
int pubhuboldhandler(int op, char *buf, size_t len)
break;
case PHO_DATA:
p = buf;
- while((p = memchr(
p, '\n', len
)) != NULL)
+ while((p = memchr(
(p2 = p), '\n', len - (p - buf)
)) != NULL)
{
*(p++) = 0;
- for(i = 0
, p2 = buf
; i < 4; i++) {
+ for(i = 0; i < 4; i++) {
fields[i] = p2;
if((p2 = strchr(p2, '|')) == NULL)
break;
@@
-73,7
+73,7
@@
int pubhuboldhandler(int op, char *buf, size_t len)
free(fields[i]);
}
}
- return(p - buf);
+ return(p
2
- buf);
break;
case PHO_EOF:
cols[0] = 3; names[0] = _("# users");