[vlc-commits] audiotrack: move error check to good scope

Thomas Guillem git at videolan.org
Wed Mar 11 16:09:54 CET 2015


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Wed Mar 11 15:51:07 2015 +0100| [f92cac88220ca7aeac054cf6db6df29abff30842] | committer: Jean-Baptiste Kempf

audiotrack: move error check to good scope

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=f92cac88220ca7aeac054cf6db6df29abff30842
---

 modules/audio_output/audiotrack.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/audio_output/audiotrack.c b/modules/audio_output/audiotrack.c
index fc3d77b..11dd08d 100644
--- a/modules/audio_output/audiotrack.c
+++ b/modules/audio_output/audiotrack.c
@@ -1342,9 +1342,9 @@ JNIThread( void *data )
                     i_buffer_offset = 0;
                     b_error = JNIThread_PreparePlay( env, p_aout, p_buffer )
                               != VLC_SUCCESS;
+                    if( b_error )
+                        break;
                 }
-                if( b_error )
-                    break;
                 b_error = JNIThread_Play( env, p_aout, p_buffer,
                                           &i_buffer_offset,
                                           &i_play_wait ) != VLC_SUCCESS;



More information about the vlc-commits mailing list