diff -dur ../iroffer1.4.b02modDinoex1.4/src/iroffer_main.c ./src/iroffer_main.c --- ../iroffer1.4.b02modDinoex1.4/src/iroffer_main.c Mon Feb 7 08:53:17 2005 +++ ./src/iroffer_main.c Thu Feb 10 20:58:33 2005 @@ -1876,8 +1876,9 @@ { int hasvoice = 0; - while ((t[0] == ':') || - (t[0] == '*') || + while (t[0] == ':') + t++; + while ((t[0] == '*') || (t[0] == '@') || (t[0] == '+') || (t[0] == '!') || @@ -1903,7 +1904,38 @@ } } } + + /* MODE channel +v nick */ + if ((gdata.need_voice != 0) && !strncmp(part2,"MODE",4) + && part3 && part4 && part5) + { + caps(part3); + + ch = irlist_get_head(&gdata.channels); + while(ch) + { + if (!strcmp(part3,ch->name)) + { + break; + } + ch = irlist_get_next(ch); + } + if (ch) + { + if (part4[0] == '+') + { + if (strpbrk(part4,"ahoqv") != NULL) + addtomemberlist(ch,part5); + } + if (part4[0] == '-') + { + if (strpbrk(part4,"ahoqv") != NULL) + removefrommemberlist(ch,part5); + } + } + } + /* ERROR :Closing Link */ if (strncmp(line, "ERROR :Closing Link", strlen("ERROR :Closing Link")) == 0) { if (gdata.exiting) diff -dur ../iroffer1.4.b02modDinoex1.4/src/iroffer_utilities.c ./src/iroffer_utilities.c --- ../iroffer1.4.b02modDinoex1.4/src/iroffer_utilities.c Sun Feb 6 23:00:06 2005 +++ ./src/iroffer_utilities.c Thu Feb 10 21:24:25 2005 @@ -1887,6 +1887,9 @@ void changeinmemberlist(channel_t *c, char *oldnick, const char *newnick) { + char *nick1; + char *member; + updatecontext(); if (gdata.debug > 2) @@ -1895,6 +1898,27 @@ "changing %s to %s in %s",oldnick,newnick,c->name); } + if (gdata.need_voice) + { + nick1 = mycalloc(strlen(oldnick)+1); + strcpy(nick1,oldnick); + caps(nick1); + + /* is in list for this channel? */ + member = irlist_get_head(&c->members); + while(member) + { + if (!strcmp(caps(member),oldnick)) + { + irlist_delete(&c->members, member); + addtomemberlist(c, newnick); + return; + } + member = irlist_get_next(member); + } + return; + } + removefrommemberlist(c, oldnick); addtomemberlist(c, newnick); Only in .: t.sh Only in .: z.sh