Bug 169190 - compiler notices dodgy code
compiler notices dodgy code
Product: Fedora
Classification: Fedora
Component: kdeutils (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Ngo Than
Ben Levenson
Depends On:
  Show dependency treegraph
Reported: 2005-09-24 07:21 EDT by David Binderman
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-10-27 15:53:44 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description David Binderman 2005-09-24 07:21:56 EDT
Description of problem:
I just tried to compile Fedora development package kdeutils-3.4.2-2
with the extra compiler flag -Wall.

The compiler said

hexprinter.cc:136: warning: 'size$height' is used uninitialized in this function

The source code is

SPageSize CHexPrinter::pageFullSize( void )
  QPaintDeviceMetrics metric( this );
  SPageSize size;
  size.width = metric.width();
  size.width = metric.height();

  return( size );

Notice that size.width gets assigned to twice. Maybe size.height was
intended on the second initialisation ?

  size.width = metric.width();
  size.height = metric.height();

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

How reproducible:

Steps to Reproduce:
Actual results:

Expected results:

Additional info:
Comment 1 Marcin Garski 2005-10-27 15:53:44 EDT
Thanks for the bug report.

Bug has been reported upstream:

I will notify when this bugs will be fixed upstream.
Comment 2 Marcin Garski 2005-10-27 19:39:18 EDT
Bug has been fixed in KDE's SVN.

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