8074832: Resolve disabled warnings for libjsoundalsa
authorserb
Sat, 18 Jul 2015 15:13:16 +0300
changeset 32111 77f01a77573d
parent 32110 733062f75808
child 32112 16954b3f94fd
8074832: Resolve disabled warnings for libjsoundalsa Reviewed-by: amenkov, azvegint
jdk/make/lib/SoundLibraries.gmk
jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c
--- a/jdk/make/lib/SoundLibraries.gmk	Sat Jul 18 15:12:08 2015 +0300
+++ b/jdk/make/lib/SoundLibraries.gmk	Sat Jul 18 15:13:16 2015 +0300
@@ -168,7 +168,6 @@
           -DUSE_PORTS=TRUE \
           -DUSE_PLATFORM_MIDI_OUT=TRUE \
           -DUSE_PLATFORM_MIDI_IN=TRUE, \
-      DISABLED_WARNINGS_gcc := parentheses, \
       MAPFILE := $(JDK_TOPDIR)/make/mapfiles/libjsoundalsa/mapfile-vers, \
       LDFLAGS := $(LDFLAGS_JDKLIB) \
           $(call SET_SHARED_LIBRARY_ORIGIN), \
--- a/jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c	Sat Jul 18 15:12:08 2015 +0300
+++ b/jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c	Sat Jul 18 15:13:16 2015 +0300
@@ -431,8 +431,8 @@
             }
         } else { // more than two channels, each channels has its own control.
             for (channel = SND_MIXER_SCHN_FRONT_LEFT; channel <= SND_MIXER_SCHN_LAST; channel++) {
-                if (isPlayback && snd_mixer_selem_has_playback_channel(elem, channel) ||
-                    !isPlayback && snd_mixer_selem_has_capture_channel(elem, channel)) {
+                if ((isPlayback && snd_mixer_selem_has_playback_channel(elem, channel)) ||
+                    (!isPlayback && snd_mixer_selem_has_capture_channel(elem, channel))) {
                     if (getControlSlot(portMixer, &portControl)) {
                         portControl->elem = elem;
                         portControl->portType = portMixer->types[portIndex];