diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2009-07-24 08:01:31 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2009-07-24 08:01:31 +0000 |
commit | b70981b68efcce5256eb11c6cd26ae123b10b6ea (patch) | |
tree | a38be6efae5e2ba15c2e839504632f9b7bfd5f91 /main/dircproxy/1.1.0-less-lag-on-attach.patch | |
parent | 2b4df81538b8398442d5296650905c70341dd8d3 (diff) | |
download | aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.bz2 aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.xz |
moved extra/* to main/
and fixed misc build issues
Diffstat (limited to 'main/dircproxy/1.1.0-less-lag-on-attach.patch')
-rw-r--r-- | main/dircproxy/1.1.0-less-lag-on-attach.patch | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/main/dircproxy/1.1.0-less-lag-on-attach.patch b/main/dircproxy/1.1.0-less-lag-on-attach.patch new file mode 100644 index 0000000000..2eb3998db1 --- /dev/null +++ b/main/dircproxy/1.1.0-less-lag-on-attach.patch @@ -0,0 +1,53 @@ +--- a/src/irc_client.c 2005-01-06 02:48:12.964637427 +0100 ++++ b/src/irc_client.c.lessflood 2005-01-06 02:47:50.433376383 +0100 +@@ -1910,13 +1910,34 @@ + /* Recall channel log files, and get channel topic and members from server */ + if (p->channels) { + struct ircchannel *c; ++ unsigned int cnames_length = 0; ++ char *cnames = 0; ++ ++ c = p->channels; ++ while (c) { ++ if (!c->inactive && !c->unjoined) { ++ cnames_length += strlen(c->name) + 1; // +1 to hold comma ++ } ++ ++ c = c->next; ++ } ++ ++ if(cnames_length) ++ { ++ cnames = (char *)malloc(cnames_length + 1); ++ memset(cnames, 0, cnames_length + 1); ++ } + + c = p->channels; + while (c) { + if (!c->inactive && !c->unjoined) { + ircclient_send_selfcmd(p, "JOIN", ":%s", c->name); +- ircserver_send_command(p, "TOPIC", ":%s", c->name); +- ircserver_send_command(p, "NAMES", ":%s", c->name); ++ if(cnames_length) { ++ if(c == p->channels) // first channel in list ++ sprintf(cnames, "%s", c->name); ++ else ++ sprintf(cnames, "%s,%s", cnames, c->name); ++ } + + if (p->conn_class->chan_log_enabled) { + irclog_autorecall(p, c->name); +@@ -1926,6 +1948,13 @@ + + c = c->next; + } ++ ++ if(cnames_length) ++ { ++ ircserver_send_command(p, "TOPIC", ":%s", cnames); ++ ircserver_send_command(p, "NAMES", ":%s", cnames); ++ free(cnames); ++ } + } + + /* Recall private log file */ |