Bug 158756 - fbi-2.03-10: local variable used before set
Summary: fbi-2.03-10: local variable used before set
Status: RESOLVED FIXED
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: unspecified
Hardware: All SuSE Linux 10.1
: P5 - None : Normal
Target Milestone: ---
Assignee: Gerd Hoffmann
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-03-16 18:41 UTC by David Binderman
Modified: 2006-03-17 12:50 UTC (History)
0 users

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Binderman 2006-03-16 18:41:55 UTC
I just tried to compile package fbi-2.03-10 with the Intel C compiler.

It said

sane.c(40): warning #592: variable "list" is used before its value is set

The source code is

    wlist = malloc(sizeof(Widget*)*nchildren);
    memcpy(list,children,sizeof(Widget*)*nchildren);

I agree with the compiler.  Suggest new code

    wlist = malloc( wsizeof(Widget*) * nchildren);
    memcpy( wlist, wchildren, wsizeof(Widget*)*nchildren);
Comment 1 Gerd Hoffmann 2006-03-17 12:50:13 UTC
Fixed in fbida cvs.