back to old irc splitting code that works with OTR

This commit is contained in:
psyc://psyced.org/~lynX 2011-06-10 08:34:40 +02:00
parent 2646840a52
commit f8231d64d8
2 changed files with 9 additions and 3 deletions

View File

@ -283,6 +283,8 @@ echo "[binary directory is $ARCH_DIR]"
## uname -m returns "Power Macintosh" on macosx. very unuseful.
##get ARCH_DIR "$BASE_DIR/bin-`uname -m`"
## why did we call uname twice anyway? uname -s returns such a nice "darwin"
## on linux it returns the actual processor type (i686, x86_64, etc)
## which these days needs to be considered.. FIXME
##
#get ARCH_DIR "$BASE_DIR/bin-$arch"
#ask "Binary installation directory" ARCH_DIR

View File

@ -336,7 +336,11 @@ emit(string output) {
}
foreach(line : outlines) if (strlen(line)) {
while (strlen(line) > cut) {
#if 1
#if 0 //{{{
// this is supposed to be the more elegant
// message continuation strategy but it
// breaks OTR over IRC! thx alice
//
// we shall look for last whitespace instead
t = rindex(line, ' ', cut);
if (t > 9) {
@ -364,7 +368,7 @@ emit(string output) {
// we might aswell use the old
// backslash splitting code below here
}
#else //{{{
#else //}}}
t = line[cut] == '\r' ? cut-1 : cut;
// msa's CTCP character
@ -382,7 +386,7 @@ emit(string output) {
+ "\\\r\n");
line = line[cut+1..];
}
#endif //}}}
#endif
}
P4(("irc:emit each %O\n", line))
EMIT(split_prefix + line +"\r\n");