Closed Bug 1194951 Opened 4 years ago Closed 4 years ago

Suppress warnings in third-party code: pocketsphinx and sphinxbase

Categories

(Core :: Web Speech, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla43
Tracking Status
firefox43 --- fixed

People

(Reporter: cpeterson, Assigned: cpeterson)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

media/pocketsphinx/src/dict.c:312:18: warning: passing 'const char *' to parameter of type 'void *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]

media/pocketsphinx/src/dict.c:571:5: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]

media/sphinxbase/src/libsphinxbase/util/blas_lite.c:101:2: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:102:3: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:105:2: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:106:3: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:425:5: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:726:5: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:1138:5: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
media/sphinxbase/src/libsphinxbase/util/blas_lite.c:1450:5: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
Attachment #8648351 - Flags: review?(kdavis)
Comment on attachment 8648351 [details] [diff] [review]
pocketsphinx-suppress-warnings.patch

Review of attachment 8648351 [details] [diff] [review]:
-----------------------------------------------------------------

::: media/pocketsphinx/moz.build
@@ +47,5 @@
>  # Suppress warnings in third-party code.
>  if CONFIG['GNU_CC']:
> +    CFLAGS += [
> +        '-Wno-declaration-after-statement',
> +        '-Wno-parentheses',

Is this needed for the pocketsphinx code? From the warnings you provided
it looks as if it's only required for the sphinxbase code.
Attachment #8648351 - Flags: review?(kdavis) → review+
(In reply to kdavis from comment #1)
> > +        '-Wno-parentheses',
> 
> Is this needed for the pocketsphinx code? From the warnings you provided
> it looks as if it's only required for the sphinxbase code.

Good catch! :) I just confirmed that -Wno-parentheses is only needed for the sphinxbase code. I'll remove that -Wno-parentheses when landing this patch.
https://hg.mozilla.org/mozilla-central/rev/dc0b3938e464
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
You need to log in before you can comment on or make changes to this bug.