]> git.sesse.net Git - vlc/commitdiff
Mmmmh an endianness bug ?
authorChristophe Massiot <massiot@videolan.org>
Mon, 11 Dec 2000 14:58:30 +0000 (14:58 +0000)
committerChristophe Massiot <massiot@videolan.org>
Mon, 11 Dec 2000 14:58:30 +0000 (14:58 +0000)
src/audio_decoder/audio_decoder_thread.c

index 319cbe23652a6d5e2404445b2edecc8255ad939f..a21b019dbc2b54d2d6b687624d5368b833452b70 100644 (file)
@@ -39,6 +39,7 @@
 #include <stdlib.h>                                      /* malloc(), free() */
 #include <sys/types.h>                        /* on BSD, uio.h needs types.h */
 #include <sys/uio.h>                                            /* "input.h" */
+#include <netinet/in.h>                                             /* ntohl */
 
 #include "threads.h"
 #include "common.h"
@@ -206,7 +207,7 @@ static void RunThread (adec_thread_t * p_adec)
             do 
             {
                 adec_byte_stream_next ( p_byte_stream );
-            } while ( !((*((u32 *)p_adec->p_data->p_payload_start) & 0xFFFFFF00) == 0x100) && (!p_adec->b_die)
+            } while ( !((U32_AT((u32 *)p_adec->p_data->p_payload_start) & 0xFFFFFF00) == 0x100) && (!p_adec->b_die)
                         && (!p_adec->b_error) );
 
             if( p_adec->b_die || p_adec->b_error )