Bug 7592

Summary: uniq -c crashes on x86-64 Mageia 2 and Cauldron while "uniq -c" from GNU coreutils sources is OK.
Product: Mageia Reporter: Shlomi Fish <shlomif>
Component: RPM PackagesAssignee: Thierry Vignaud <thierry.vignaud>
Status: RESOLVED FIXED QA Contact:
Severity: critical    
Priority: Normal CC: nic
Version: CauldronKeywords: UPSTREAM
Target Milestone: ---   
Hardware: x86_64   
OS: Linux   
See Also: https://bugzilla.redhat.com/show_bug.cgi?id=869442
Whiteboard: MGA2TOO
Source RPM: coreutils-8.19-1.mga3.src.rpm CVE:
Status comment:
Attachments: The input file compressed by xz.

Description Shlomi Fish 2012-09-26 22:09:07 CEST
Description of problem:

I'm going to add an attachment. Doing:

unxz < uniq-c.crash.txt.xz | uniq -c

generates an indication of a Segmentation fault on both Mageia 2 x86-64 and Mageia Cauldron x86-64. This does not happen with unxz < uniq-c.crash.txt.xz | ~/apps/temp-coreutils/bin/uniq -c (where this uniq was installed using "./configure --prefix="$HOME/apps/temp-coreutils" ; "make" ; "make install" from the GNU coreutils sources).

The file contains a long line of items separated by CRs, due to a mis-generation (which was since fixed) but uniq still should not crash.

How reproducible:

Always
Comment 1 Shlomi Fish 2012-09-26 22:10:11 CEST
Created attachment 2866 [details]
The input file compressed by xz.

This is the input file as compressed by the "xz" compressor.
Shlomi Fish 2012-09-26 22:11:24 CEST

Whiteboard: (none) => MGA2TOO

Comment 2 Shlomi Fish 2012-09-26 23:32:54 CEST
OK, after some amount of investigation (thanks to Luigi12_work from IRC for some insights), we found out that the problem was with coreutils-8.19-new-i18n.patch patch. If we remove it, do "bm -l -p" and run "./configure --prefix ; make ; make install", then the unxz < ... | ~/apps/temp-coreutils-rpm/uniq -c works fine. With all patches applied it segfaults.

This patch is identical to this Fedora patch:

http://pkgs.fedoraproject.org/cgit/coreutils.git/plain/coreutils-i18n.patch

Thierry, can you please report it there?

Regards,

-- Shlomi Fish

Assignee: bugsquad => thierry.vignaud

Comment 3 Shlomi Fish 2012-10-24 00:28:03 CEST
Added the report on the Red Hat bugzilla.

See Also: (none) => https://bugzilla.redhat.com/show_bug.cgi?id=869442

Thierry Vignaud 2012-10-24 01:53:11 CEST

Keywords: (none) => UPSTREAM

Comment 4 Nic Baxter 2015-03-13 05:18:48 CET
Not reproducible on 5Beta3 so must have been fixed.

Status: NEW => RESOLVED
CC: (none) => nic
Resolution: (none) => FIXED