🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #17542

Another trn mini-patch

#17542
From: Olaf Titz
Date: Sun, 12 Nov 1995 00:00
26 lines
1435 bytes
Some uuencoding/posting software from the DOS world puts out
Control-Ms at the end of each line. trn 3.6 doesn't handle (i.e.
ignore) these correctly. The following patch fixes that.

olaf

--- uudecode.c.orig	Sat Oct 28 15:05:21 1995
+++ uudecode.c	Sat Oct 28 15:07:35 1995
@@ -85,6 +85,11 @@
 
     while ((state & NO_ADVANCE) || fgets(buff, sizeof buff, in) != Nullch) {
 	numl++;
+	lens = strlen(buff)-2;
+	if (buff[lens] == '\r') {
+	  buff[lens] = buff[lens+1];
+	  buff[lens+1] = '\0';
+	}
 
 	switch (state) {
 	 case NEW_BEGIN:

-- 
___        Olaf.Titz@inka.de or @{stud,informatik}.uni-karlsruhe.de       ____
__ o           <URL:http://www.inka.de/~bigred/>     <IRC:praetorius>
__/<_              >> Just as long as the wheels keep on turning round
_)>(_)______________ I will live for the groove 'til the sun goes down << ____
Technical Details
Message-ID: <dhxxio.don@bigred.inka.de>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-alt.sources.mbox.zip!not-for-mail

Show Full Headers
Complete Article Headers
Message-ID: <dhxxio.don@bigred.inka.de>
Subject: Another trn mini-patch
Date: Sun, 12 Nov 1995 00:00:00 +0000
From: Olaf Titz <olaf@bigred.inka.de>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-alt.sources.mbox.zip!not-for-mail
X-Deja-AN: 119224307
Organization: private Linux site, southern Germany
Followup-to: news.software.readers,alt.sources.d
Newsgroups: news.software.readers,alt.sources