Bug 162137 - operation on 'outidx' is undefined
operation on 'outidx' is undefined
Product: Fedora
Classification: Fedora
Component: festival (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Matthew Miller
Depends On: festival1.96
  Show dependency treegraph
Reported: 2005-06-30 05:48 EDT by David Binderman
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version: 1.96-0.11
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-03-20 15:02:02 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

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

  None (edit)
Description David Binderman 2005-06-30 05:48:19 EDT
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:
Actual results:

Expected results:

Additional info:
Comment 1 John (J5) Palmieri 2005-06-30 10:17:13 EDT
Can you create a patch, attach it here and send it upstream?  Thanks.
Comment 2 David Binderman 2005-07-01 04:17:53 EDT
>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 17:00:29 EDT
I'm working on an updated package which includes this fix. Still should be sent
Comment 4 Matthew Miller 2007-03-13 17:20:27 EDT
See bug #232105 for in-progress updated packages which address this issue.
Comment 5 Matthew Miller 2007-03-14 07:03:47 EDT
Created attachment 150027 [details]
the patch, for reference

here's the patch, for reference.
Comment 6 Matthew Miller 2007-03-20 15:02:02 EDT
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.