Package: knews-1.0b.1 The do_xover function of knewsd prints LINE-CR-LF if the line from the .overview file is longer than 1024 characters, but it prints only the raw line from the file (i.e. LINE-LF) if the line is shorter. This is a problem if knewsd is used by a news client other than knews, e.g. with knode www.geocrawler.com/archives/3/3730/2002/9/0/9501787/ The client doesn't even recognize the end of the transmission, since the closing period is at the end of one huge "line", not at the beginning of the last line. --- knewsdold.c Mon Aug 31 15:40:05 1998 +++ knewsd.c Thu Aug 1 18:16:04 2002 @@ -619,6 +619,7 @@ FILE *fp = NULL; long first, last, no; char *c; + char *lfl = NULL; if (!group_path) { printf(CODE_TO_STR(NNTP_ERR_NCING) " Not in a newsgroup.\r\n"); @@ -677,15 +678,18 @@ if (no > last) break; + lfl = strchr(buffer, '\n'); + if (lfl) + lfl[0]=0; fputs(buffer, stdout); - if (!strchr(buffer, '\n')) { + if (!lfl) { int ch; while ((ch = getc(fp)) != EOF && ch != '\n') putchar(ch); - - printf("\r\n"); } + + printf("\r\n"); } fclose(fp); Achim
did you send this patch upstream too?
I sent it to Debian and SuSE. AFAIK the upstream is no longer active.
Hm. knews is masked as "broken" since times immemorial. If it's dead upstream we should remove it from potage altogether, not go on fixing it.
knews is probably the only GUI news reader for unix with acceptable performance on a small box, and knewsd is the only easy way to use a news spool with online-only news readers like knode. Debian and SuSE still maintain knews packages for their current distributions and there are still some people who use it, so I don't know what "broken" means in this context.
I don' know what's so broken about it either, I think the mask is from before my time... I'll check.
Sorry! I was thinking of an entirely different app as it turns out. I only now realized what it is we're talking about and that the k in knews doesn't mean it's a kde app. I believe Seemant made that mistake too and that's why he assigned it to the kde@gentoo.org list. Seemant, please send this where it belongs (I believe phoenix had something to do with it?)
achim, ok, I have the fix in waiting to be committed, but knews just isn't compiling at all. I keep getting libpng errors: gcc -O2 -Wall -I../Widgets -I/usr/include -I/usr/X11R6/include -Dlinux -D__i386__ -D_POSIX_C_SOURCE=199309L -D_POSIX_SOURCE -D_XOPEN_SOURCE -D_BSD_SOURCE -D_SVID_SOURCE -DFUNCPROTO=15 -DNARROWPROTO -c -o png.o png.c png.c: In function `do_png': png.c:111: warning: implicit declaration of function `png_read_init' png.c:112: invalid lvalue in unary `&' make[1]: *** [png.o] Error 1 make[1]: Leaving directory `/var/tmp/portage/knews-1.0.1b-r1/work/knews-1.0b.1/src' make: *** [all] Error 2 what do you make of that?
Either switch it off in configure.h #define HAVE_PNG 0 (and set HAVE_COMPFACE to 0 if you don't have libcompface) or get the patch for png.c from the Debian diff ftp.debian.org/debian/pool/main/k/knews/knews_1.0b.1-9.diff.gz Works for me (libpng-1.2.x).
thanks for this achim.