A little cosmetic problem...

Martin Köhling <[email protected]> Wed, 6 Dec 2006 20:38:42 +0100 (CET)
Newsgroups gmane.linux.suse.fou4s.devel
Message-ID <[email protected]>
Hi!

Some update descriptions contain spurious cariage return ('\r') characters in
the middle of the line, causing fou4s to display them in a rather unreadable
fashion, like this:

============== Update Information for libpng-53096 (2006-11-30) ==============
libpng: Security update to fix sPLT overflow.
 PNG filechunk handling in libpng was incorrect and a handcrafted
 crashing the PNGause an out-of-bounds read, effectively
viewer or webbrowser. (CVE-2006-5793)
 toitionaly a 2 byte stackoverflow was fixed which we do not believe
 in SUSEitable. It will cause an abort of the viewer or webbrowser
Linux 10.0 and newer due to string overflow checking. (CVE-2006-3334)
===============================================================================
libpng                 1.2.8-3.3     (1.2.8-3      ) [ok] security       64kb


This is a rare problem; I've found only four of these cases in SUSE 9.3:

# egrep -l $'\r' /var/cache/fou4s/packages/ftp.gwdg.de/i386/update/9.3/patches/*
/var/cache/fou4s/packages/ftp.gwdg.de/i386/update/9.3/patches/gv-53084
/var/cache/fou4s/packages/ftp.gwdg.de/i386/update/9.3/patches/libpng-53096
/var/cache/fou4s/packages/ftp.gwdg.de/i386/update/9.3/patches/links-53091
/var/cache/fou4s/packages/ftp.gwdg.de/i386/update/9.3/patches/phpMyAdmin-53093


Anyway, here's a quick 'n easy fix for fou4s-0.14.1-2:
(Applies to fou4s-0.15.0-0.3, too.)

--- fou4s.ORIG  2006-06-07 09:45:54.000000000 +0200
+++ fou4s       2006-12-06 12:26:28.000000000 +0100
@@ -1096,6 +1096,7 @@
                lang=$LANGUAGE gnal=$EGAUGNAL
                checkLanguage "`awk
		"/Longdescription.$LANGUAGE:/,/$EGAUGNAL.noitpircsedgnol:/"
		$pkgdescfile`" || { lang=english gnal=Hsilgne ; }
                awk "/Longdescription.$lang:/,/$gnal.noitpircsedgnol:/"
		$pkgdescfile \
+                       | tr --delete '\r' \
                        | sed 's/^- -/\n- /g'| sed '1d;$d' | myRecode | fmt
			-$width | grep -v "^$"
                echo -e ${line:0:$width}$COL_NORM # show this line only in
		length of the above
        #else


Martin

-- 
Email sender address above might go away soon (depending an spam volume); use
mk@same-domain for any replies. Thank you.:-)
--