Bug 162137 - operation on 'outidx' is undefined
Summary: operation on 'outidx' is undefined
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: festival
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Matthew Miller
QA Contact:
URL:
Whiteboard:
Depends On: festival1.96
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-06-30 09:48 UTC by David Binderman
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version: 1.96-0.11
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-03-20 19:02:02 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
the patch, for reference (466 bytes, patch)
2007-03-14 11:03 UTC, Matthew Miller
no flags Details | Diff

Description David Binderman 2005-06-30 09:48:19 UTC
Description of problem:

I just tried to compile package festival-1.95-3 from Redhat
Fedora Core development tree with the gcc 4.0.0 compiler and
the compiler flag -Wall.

The compiler said

rateconv.cc:387: warning: operation on 'outidx' may be undefined

The source code is

            fir_stereo(inp + inoffset + inbaseidx,
                       coep + cycctr * firlen, firlen,
                       outp + outidx++, outp + outidx++);

I agree with the compiler - this is undefined code. Suggest avoid
incrementing variable "outidx" twice between sequence points.

Better code might be

            fir_stereo(inp + inoffset + inbaseidx,
                       coep + cycctr * firlen, firlen,
                       outp + outidx, outp + outidx + 1);
            outidx += 2;



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


How reproducible:


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


Expected results:


Additional info:

Comment 1 John (J5) Palmieri 2005-06-30 14:17:13 UTC
Can you create a patch, attach it here and send it upstream?  Thanks.

Comment 2 David Binderman 2005-07-01 08:17:53 UTC
>Can you create a patch

I could, but I have no way to test the patch in the festival package.

Suggest forward bug report to upstream.

Comment 3 Matthew Miller 2007-03-13 21:00:29 UTC
I'm working on an updated package which includes this fix. Still should be sent
upstream.

Comment 4 Matthew Miller 2007-03-13 21:20:27 UTC
See bug #232105 for in-progress updated packages which address this issue.

Comment 5 Matthew Miller 2007-03-14 11:03:47 UTC
Created attachment 150027 [details]
the patch, for reference

here's the patch, for reference.

Comment 6 Matthew Miller 2007-03-20 19:02:02 UTC
This issue should be resolved by the release of festival-1.96-0.11, now in the
development tree. (See bug #232105 for details.)

Please reopen if there's still a problem. Thanks.


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