Bug 151084

Summary: kbilliards-0.8.6-3: local variable used before set
Product: [openSUSE] SUSE LINUX 10.0 Reporter: David Binderman <dcb314>
Component: BasesystemAssignee: Michael Skibbe <mskibbe>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Minor    
Priority: P5 - None    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: SuSE Linux 10.1   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description David Binderman 2006-02-15 09:17:37 UTC
I just tried to compile package kbilliards-0.8.6-3 with a prerelease version 4.2
of the GNU C compiler.

It said

./src/soundmodule.cpp:77: warning: "e" is used uninitialized in this function

The source code is

  QTimerEvent * e; // e(QEvent::Timer) ;
  KURL pathfile(path_sound + file );

  if ( musicEngine->load(pathfile) )
       timerEvent( e ); // ( &e );

Suggest initialise local variable "e" before first use.
Comment 1 Michael Gross 2006-02-15 13:24:16 UTC
Why is this a security risk?
Comment 2 David Binderman 2006-02-15 21:09:08 UTC
(In reply to comment #1)
> Why is this a security risk?

I made no mention of security in my original bug report,
but I'll have a go anyway.

I can say that the function timerEvent obviously gets given
random data. That may be a security risk, beyond the usual
programming error.




Comment 3 Michael Gross 2006-02-16 11:52:05 UTC
I'll reassign this to Michael. Can take some time until it gets fixed, he's absent at the moment.
Comment 4 Michael Skibbe 2006-03-02 07:35:56 UTC
i fixed this.