Bug 671 - segfault in rpm 2.5.* while doing rpm -i or rpm -U
segfault in rpm 2.5.* while doing rpm -i or rpm -U
Status: CLOSED WORKSFORME
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
5.2
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Jeff Johnson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-01-02 20:55 EST by Steven Pritchard
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-01-04 16:58:41 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Steven Pritchard 1999-01-02 20:55:19 EST
rpm 2.5.* segfaulted while trying to upgrade various
packages that apparently have shared files.  A bit of
debugging on 2.5.7 (from the rawhide srpm) showed that the
segfault was happening on line 1324 of lib/install.c, which
reads as follows (in case that number isn't right):

        state =
secFileStatesList[sharedList[i].secFileNumber];

Apparently secFileStatesList was NULL, which caused the
segfault.  Not knowing anything about the code, I wasn't
sure why that was NULL, but on a whim I tried wrapping that
little block (the line above plus the 7 lines after it) in
#if 0.  I don't know what that's likely to have broken, but
it did let me install the packages.

This happened while trying to upgrade to the 5.2 rpms from a
(*ahem*) rather personalized 5.1 system (former Slackware
2.0 system hand-upgraded to rh 4.something on up to 5.2
now).  My guess would be that there is some sort of
inconsistency in the rpm database, but that's only a wild
guess.  I tried several versions of rpm.  (I'm afraid I
didn't keep track of exactly with ones, but I think I tried
the versions from 5.1, 5.2, and the current rawhide.)
Comment 1 David Lawrence 1999-01-04 15:23:59 EST
This bug has been assigned to a developer for further review.
Please mail any patches or diffs as described in the bugzilla
instruction pages.
Comment 2 Jeff Johnson 1999-01-04 16:58:59 EST
Your guess that the segfault is caused by incorrect
information retrieved from the database appears
correct.
Try "rpm --rebuilddb" after any/every rpm segfault. Please
reopen this bug if the problem persists after doing
"rpm --rebuilddb"

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