[vlc-devel] [PATCH 5/6] decoder: fix compilation on OS/2

KO Myung-Hun komh78 at gmail.com
Sun Oct 11 13:00:56 CEST 2020


-----
input/decoder.c: In function 'decoder_New':
../include/vlc_threads.h:99:39: error: missing binary operator before token "("
   99 | # define VLC_THREAD_PRIORITY_AUDIO    MAKESHORT(PRTYD_MAXIMUM, PRTYC_REGULAR)
      |                                       ^~~~~~~~~
input/decoder.c:2048:5: note: in expansion of macro 'VLC_THREAD_PRIORITY_AUDIO'
 2048 | #if VLC_THREAD_PRIORITY_AUDIO != VLC_THREAD_PRIORITY_VIDEO
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~
-----
---
 src/input/decoder.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/src/input/decoder.c b/src/input/decoder.c
index cc3f69d740..b02a515c4b 100644
--- a/src/input/decoder.c
+++ b/src/input/decoder.c
@@ -2020,7 +2020,7 @@ decoder_New( vlc_object_t *p_parent, const es_format_t *fmt,
              const struct vlc_input_decoder_callbacks *cbs, void *userdata)
 {
     const char *psz_type = p_sout ? N_("packetizer") : N_("decoder");
-    int i_priority;
+    int i_priority = VLC_THREAD_PRIORITY_VIDEO;
 
     /* Create the decoder configuration structure */
     vlc_input_decoder_t *p_owner =
@@ -2045,12 +2045,8 @@ decoder_New( vlc_object_t *p_parent, const es_format_t *fmt,
 
     assert( p_dec->fmt_in.i_cat != UNKNOWN_ES );
 
-#if VLC_THREAD_PRIORITY_AUDIO != VLC_THREAD_PRIORITY_VIDEO
     if( p_dec->fmt_in.i_cat == AUDIO_ES )
         i_priority = VLC_THREAD_PRIORITY_AUDIO;
-    else
-#endif
-        i_priority = VLC_THREAD_PRIORITY_VIDEO;
 
 #ifdef ENABLE_SOUT
     /* Do not delay sout creation for SPU or DATA. */
-- 
2.22.0



More information about the vlc-devel mailing list