Bug 40555 - librpm calls abort()
Summary: librpm calls abort()
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
(Show other bugs)
Version: 7.1
Hardware: All Linux
Target Milestone: ---
Assignee: Jeff Johnson
QA Contact: David Lawrence
Depends On:
TreeView+ depends on / blocked
Reported: 2001-05-14 14:58 UTC by Daniel Veillard
Modified: 2007-04-18 16:33 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-05-14 14:58:39 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Daniel Veillard 2001-05-14 14:58:35 UTC
Description of Problem:
librpm aborts making impossible to build reliable applications with it

How Reproducible:
use rpm2html to index some broken RPM like egcs-c++-1.1b-2.sparc.rpm
from the libc6 Sparc contrib
I assume rpm(1) will do the same

Steps to Reproduce:
1. get the broken RPM 
2. run rpm under gdb
3. put a breakpoint in exit and run it on the RPM

Actual Results: this with rpm2html:
Program received signal SIGABRT, Aborted.
0x401c8801 in __kill () from /lib/i686/libc.so.6
(gdb) where
#0  0x401c8801 in __kill () from /lib/i686/libc.so.6
#1  0x401c85da in raise (sig=6) at ../sysdeps/posix/raise.c:27
#2  0x401c9d82 in abort () at ../sysdeps/generic/abort.c:88
#3  0x401c1cca in __assert_fail () at assert.c:60
#4  0x4009b645 in headerLoad () from /usr/lib/librpm.so.0
#5  0x4009c1b4 in headerRead () from /usr/lib/librpm.so.0
#6  0x400a56fc in readPackageHeaders () from /usr/lib/librpm.so.0
#7  0x400a5980 in rpmReadPackageHeader () from /usr/lib/librpm.so.0
#8  0x0804c9bc in rpmOpen (nameRpm=0x809379b "egcs-c++-1.1b-2.sparc.rpm", 
    dir=0x808bf48, tree=0x80932e0) at rpmopen.c:949
#9  0x0804cdbd in rpmOneDirScan (dir=0x808bf48, tree=0x80932e0)
    at rpmopen.c:1174
#10 0x0804cf50 in rpmDirScan (dir=0x808bf48, tree=0x807ec48) at
#11 0x0804d331 in rpmDirScanOneDir (
    directory=0xbffff91e "/serveur/ftp/linux/contrib/libc6/sparc")
    at rpmopen.c:1382
#12 0x0804a811 in main (argc=4, argv=0xbffff79c) at rpm2html.c:175
#13 0x401b7177 in __libc_start_main (main=0x804a340 <main>, argc=4, 
    ubp_av=0xbffff79c, init=0x8049a14 <_init>, fini=0x80602c0 <_fini>, 
    rtld_fini=0x4000e184 <_dl_fini>, stack_end=0xbffff78c)
    at ../sysdeps/generic/libc-start.c:129
(gdb) r

Expected Results:
a failure of the rpmReadPackageHeader() call

Additional Information:

Comment 1 Jeff Johnson 2001-05-20 18:35:00 UTC
Should be mostly fixed in rpm-4.0.3-0.24 and later. There may still be some
obscure pathways that fail with bad data on assert, so please reopen with
a test case if you find such a pathway, and I'll get that pathway fixed as well.

Note You need to log in before you can comment on or make changes to this bug.