Bug 117332 - calling free on random pointer value
Summary: calling free on random pointer value
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: prelink (Show other bugs)
(Show other bugs)
Version: rawhide
Hardware: All Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-03-02 21:33 UTC by d.binderman
Modified: 2007-11-30 22:10 UTC (History)
0 users

Fixed In Version: 0.3.1-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-03-04 17:37:48 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2004:386 normal SHIPPED_LIVE Updated prelink package 2004-09-02 04:00:00 UTC

Description d.binderman 2004-03-02 21:33:12 UTC
Description of problem:

I just tried to compile Core2 Test1 package prelink-0.3.0-20

The compiler said

prelink.c(348): remark #592: variable "data" is used before its value
is set

The source code is

         free (data.d_buf);

Calling free on uninit local variable data is deeply unwise.  Suggest init
data.d_buf before first use.



Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Jakub Jelinek 2004-03-02 22:20:30 UTC
Thanks, fixed in my tree.  Bigger bug is that GCC doesn't warn about
this (only when the variable is not aggregate).  ++todo.

Comment 2 Jay Turner 2004-09-02 05:19:47 UTC
An errata has been issued which should help the problem 
described in this bug report. This report is therefore being 
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, 
please follow the link below. You may reopen this bug report 
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2004-386.html



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