Bug 136149 - missing return statement
Summary: missing return statement
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: dvgrab
Version: 3
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Warren Togami
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-10-18 11:48 UTC by David Binderman
Modified: 2007-11-30 22:10 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2004-10-18 11:50:32 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description David Binderman 2004-10-18 11:48:04 UTC
Description of problem:

I just tried to compile package dvgrab-1.6-1 from package
Redhat Fedora Core 3 Test 3.

The compiler said

smiltime.cc(349): warning #1011: missing return statement at end of
non-void function "SMIL::Time::serialise"

The source code is

string Time::serialise()
{
        toString();
}

Might be worthwhile putting in a return statement at the end of
the function.


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


How reproducible:


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


Expected results:


Additional info:

Comment 1 Warren Togami 2004-10-18 11:50:32 UTC
Unless this is an actual software defect that causes bad behavior or
crashes, is it inappropriate to complain about compiler warnings here.
 Please make sure this is fixed at the upstream dvgrab project.

Comment 2 David Binderman 2005-03-09 14:24:24 UTC
>Unless this is an actual software defect that causes bad behavior

Returning stack rubbish to the caller is one of the oldest C++ mistakes
in the book.

I'm surprised the C++ compiler accepts this code. It is a certain
software defect every time this code is executed.


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