]> git.sesse.net Git - vlc/commitdiff
* ./include/*, ./src/*: separated WIN32 #tests and UNDER_CE #tests, because
authorSam Hocevar <sam@videolan.org>
Mon, 11 Nov 2002 14:39:12 +0000 (14:39 +0000)
committerSam Hocevar <sam@videolan.org>
Mon, 11 Nov 2002 14:39:12 +0000 (14:39 +0000)
    WIN32 isn't always defined under WinCE, but might be. Grmbl.
  * ./include/*: changed a few u* and s* to uint*_t and int*_t.

40 files changed:
include/aout_internal.h
include/audio_output.h
include/input_ext-dec.h
include/input_ext-intf.h
include/input_ext-plugins.h
include/interface.h
include/iso_lang.h
include/main.h
include/mmx.h
include/modules.h
include/mtime.h
include/os_specific.h
include/variables.h
include/video.h
include/video_output.h
include/vlc_common.h
include/vlc_config.h
include/vlc_cpu.h
include/vlc_threads.h
include/vlc_threads_funcs.h
src/extras/dirent.c
src/extras/getopt.c
src/input/input.c
src/input/input_clock.c
src/input/input_dec.c
src/input/input_ext-dec.c
src/input/input_ext-intf.c
src/input/input_ext-plugins.c
src/input/input_info.c
src/input/input_programs.c
src/interface/intf_eject.c
src/misc/configuration.c
src/misc/cpu.c
src/misc/messages.c
src/misc/modules.c
src/misc/modules_plugin.h.in
src/misc/mtime.c
src/misc/netutils.c
src/misc/threads.c
src/stream_output/stream_output.c

index d1df3a2a65a1f9a388d9d3c8a08f492d74729ff8..cc788d520e8e72ac57503155b4b8d531c6ffd2f5 100644 (file)
@@ -2,7 +2,7 @@
  * aout_internal.h : internal defines for audio output
  *****************************************************************************
  * Copyright (C) 2002 VideoLAN
- * $Id: aout_internal.h,v 1.30 2002/11/10 14:31:46 gbazin Exp $
+ * $Id: aout_internal.h,v 1.31 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -54,7 +54,7 @@ typedef struct aout_alloc_t
     else                                                                    \
     {                                                                       \
         int i_alloc_size;                                                   \
-        i_alloc_size = (u64)(p_alloc)->i_bytes_per_sec                      \
+        i_alloc_size = (uint64_t)(p_alloc)->i_bytes_per_sec                 \
                                             * (i_nb_usec) / 1000000 + 1;    \
         ALLOCA_TEST( p_alloc, p_new_buffer )                                \
         {                                                                   \
@@ -278,7 +278,7 @@ VLC_EXPORT( int, aout_FormatNbChannels, ( audio_sample_format_t * p_format ) );
 VLC_EXPORT( void, aout_FormatPrepare, ( audio_sample_format_t * p_format ) );
 VLC_EXPORT( void, aout_FormatPrint, ( aout_instance_t * p_aout, const char * psz_text, const audio_sample_format_t * p_format ) );
 VLC_EXPORT( void, aout_FormatsPrint, ( aout_instance_t * p_aout, const char * psz_text, const audio_sample_format_t * p_format1, const audio_sample_format_t * p_format2 ) );
-void aout_FifoInit( aout_instance_t *, aout_fifo_t *, u32 );
+void aout_FifoInit( aout_instance_t *, aout_fifo_t *, uint32_t );
 mtime_t aout_FifoNextStart( aout_instance_t *, aout_fifo_t * );
 void aout_FifoPush( aout_instance_t *, aout_fifo_t *, aout_buffer_t * );
 void aout_FifoSet( aout_instance_t *, aout_fifo_t *, mtime_t );
index 716245c82f4ea9136f6a93e8631d5f23c8ab761c..47b7b348b6435e42389940e7269a331d791774ee 100644 (file)
@@ -2,7 +2,7 @@
  * audio_output.h : audio output interface
  *****************************************************************************
  * Copyright (C) 2002 VideoLAN
- * $Id: audio_output.h,v 1.69 2002/10/20 12:23:47 massiot Exp $
+ * $Id: audio_output.h,v 1.70 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -85,7 +85,7 @@ struct audio_sample_format_t
  * integers, but multiplication requires shifting the 64-bit result
  * from 56 fractional bits back to 28 (and rounding.)
  */
-typedef s32 vlc_fixed_t;
+typedef int32_t vlc_fixed_t;
 #define FIXED32_FRACBITS 28
 #define FIXED32_MIN ((vlc_fixed_t) -0x80000000L)
 #define FIXED32_MAX ((vlc_fixed_t) +0x7fffffffL)
@@ -145,9 +145,9 @@ struct aout_buffer_t
  *****************************************************************************/
 struct audio_date_t
 {
-    mtime_t date;
-    u32     i_divider;
-    u32     i_remainder;
+    mtime_t  date;
+    uint32_t i_divider;
+    uint32_t i_remainder;
 };
 
 /*****************************************************************************
@@ -157,11 +157,11 @@ struct audio_date_t
 #define aout_New(a) __aout_New(VLC_OBJECT(a))
 VLC_EXPORT( aout_instance_t *, __aout_New, ( vlc_object_t * ) );
 VLC_EXPORT( void, aout_Delete, ( aout_instance_t * ) );
-VLC_EXPORT( void, aout_DateInit, ( audio_date_t *, u32 ) );
+VLC_EXPORT( void, aout_DateInit, ( audio_date_t *, uint32_t ) );
 VLC_EXPORT( void, aout_DateSet, ( audio_date_t *, mtime_t ) );
 VLC_EXPORT( void, aout_DateMove, ( audio_date_t *, mtime_t ) );
 VLC_EXPORT( mtime_t, aout_DateGet, ( const audio_date_t * ) );
-VLC_EXPORT( mtime_t, aout_DateIncrement, ( audio_date_t *, u32 ) );
+VLC_EXPORT( mtime_t, aout_DateIncrement, ( audio_date_t *, uint32_t ) );
 
 /* From dec.c : */
 #define aout_DecNew(a, b, c) __aout_DecNew(VLC_OBJECT(a), b, c)
index 22440791ff8b725e3260e8283f6b440f33958588..0082f509ad948f95d0e5649fd5a23b8c81c652d1 100644 (file)
@@ -2,7 +2,7 @@
  * input_ext-dec.h: structures exported to the VideoLAN decoders
  *****************************************************************************
  * Copyright (C) 1999-2001 VideoLAN
- * $Id: input_ext-dec.h,v 1.76 2002/11/09 16:34:52 sam Exp $
+ * $Id: input_ext-dec.h,v 1.77 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *          Michel Kaempf <maxx@via.ecp.fr>
@@ -102,7 +102,7 @@ struct decoder_fifo_t
     input_buffers_t    *p_packets_mgt;   /* packets management services data */
 
     /* Standard pointers given to the decoders as a toolbox. */
-    u16                 i_id;
+    uint16_t            i_id;
     vlc_fourcc_t        i_fourcc;
     es_sys_t *          p_demux_data;
     stream_ctrl_t *     p_stream_ctrl;
@@ -119,7 +119,7 @@ struct decoder_fifo_t
  * This type describes a bit fifo used to store bits while working with the
  * input stream at the bit level.
  *****************************************************************************/
-typedef u32         WORD_TYPE;
+typedef uint32_t    WORD_TYPE;
 
 typedef struct bit_fifo_t
 {
@@ -196,12 +196,12 @@ struct bit_stream_t
  * results will be returned. Use RealignBits() if unsure.
  */
 
-#if (WORD_TYPE == u32)
+#if (WORD_TYPE == uint32_t)
 #   define WORD_AT      U32_AT
-#   define WORD_SIGNED  s32
-#elif (WORD_TYPE == u64)
+#   define WORD_SIGNED  int32_t
+#elif (WORD_TYPE == uint64_t)
 #   define WORD_AT      U64_AT
-#   define WORD_SIGNED  s64
+#   define WORD_SIGNED  int64_t
 #else
 #   error Unsupported WORD_TYPE
 #endif
@@ -212,9 +212,9 @@ struct bit_stream_t
 VLC_EXPORT( int, InitBitstream, ( bit_stream_t *, decoder_fifo_t *, void ( * )( bit_stream_t *, vlc_bool_t ), void * p_callback_arg ) );
 VLC_EXPORT( vlc_bool_t, NextDataPacket,    ( decoder_fifo_t *, bit_stream_t * ) );
 VLC_EXPORT( void, BitstreamNextDataPacket, ( bit_stream_t * ) );
-VLC_EXPORT( u32,  UnalignedShowBits,       ( bit_stream_t *, unsigned int ) );
+VLC_EXPORT( uint32_t, UnalignedShowBits,   ( bit_stream_t *, unsigned int ) );
 VLC_EXPORT( void, UnalignedRemoveBits,     ( bit_stream_t * ) );
-VLC_EXPORT( u32,  UnalignedGetBits,        ( bit_stream_t *, unsigned int ) );
+VLC_EXPORT( uint32_t, UnalignedGetBits,    ( bit_stream_t *, unsigned int ) );
 VLC_EXPORT( void, CloseBitstream,          ( bit_stream_t * ) );
 VLC_EXPORT( void, CurrentPTS,              ( bit_stream_t *, mtime_t *, mtime_t * ) );
 VLC_EXPORT( void, NextPTS,                 ( bit_stream_t *, mtime_t *, mtime_t * ) );
@@ -250,7 +250,8 @@ static inline void AlignWord( bit_stream_t * p_bit_stream )
 /*****************************************************************************
  * ShowBits : return i_bits bits from the bit stream
  *****************************************************************************/
-static inline u32 ShowBits( bit_stream_t * p_bit_stream, unsigned int i_bits )
+static inline uint32_t ShowBits( bit_stream_t * p_bit_stream,
+                                 unsigned int i_bits )
 {
     if( (unsigned int)p_bit_stream->fifo.i_available >= i_bits )
     {
@@ -272,8 +273,8 @@ static inline u32 ShowBits( bit_stream_t * p_bit_stream, unsigned int i_bits )
  * ShowSignedBits : return i_bits bits from the bit stream, using signed
  *                  arithmetic
  *****************************************************************************/
-static inline s32 ShowSignedBits( bit_stream_t * p_bit_stream,
-                                  unsigned int i_bits )
+static inline int32_t ShowSignedBits( bit_stream_t * p_bit_stream,
+                                      unsigned int i_bits )
 {
     if( (unsigned int)p_bit_stream->fifo.i_available >= i_bits )
     {
@@ -318,7 +319,7 @@ static inline void RemoveBits( bit_stream_t * p_bit_stream,
  * RemoveBits32 : removes 32 bits from the bit buffer (and as a side effect,
  *                refill it)
  *****************************************************************************/
-#if (WORD_TYPE == u32)
+#if (WORD_TYPE == uint32_t)
 static inline void RemoveBits32( bit_stream_t * p_bit_stream )
 {
     if( p_bit_stream->p_byte <= p_bit_stream->p_end - sizeof(WORD_TYPE) )
@@ -348,9 +349,10 @@ static inline void RemoveBits32( bit_stream_t * p_bit_stream )
  * GetBits : returns i_bits bits from the bit stream and removes them
  *           XXX: do not use for 32 bits, see GetBits32
  *****************************************************************************/
-static inline u32 GetBits( bit_stream_t * p_bit_stream, unsigned int i_bits )
+static inline uint32_t GetBits( bit_stream_t * p_bit_stream,
+                                unsigned int i_bits )
 {
-    u32             i_result;
+    uint32_t        i_result;
 
     p_bit_stream->fifo.i_available -= i_bits;
 
@@ -385,12 +387,12 @@ static inline u32 GetBits( bit_stream_t * p_bit_stream, unsigned int i_bits )
  *                 using signed arithmetic
  *                 XXX: do not use for 32 bits
  *****************************************************************************/
-static inline s32 GetSignedBits( bit_stream_t * p_bit_stream,
-                                 unsigned int i_bits )
+static inline int32_t GetSignedBits( bit_stream_t * p_bit_stream,
+                                     unsigned int i_bits )
 {
     if( (unsigned int)p_bit_stream->fifo.i_available >= i_bits )
     {
-        s32             i_result;
+        int32_t         i_result;
 
         p_bit_stream->fifo.i_available -= i_bits;
         i_result = (WORD_SIGNED)p_bit_stream->fifo.buffer
@@ -407,10 +409,10 @@ static inline s32 GetSignedBits( bit_stream_t * p_bit_stream,
 /*****************************************************************************
  * GetBits32 : returns 32 bits from the bit stream and removes them
  *****************************************************************************/
-#if (WORD_TYPE == u32)
-static inline u32 GetBits32( bit_stream_t * p_bit_stream )
+#if (WORD_TYPE == uint32_t)
+static inline uint32_t GetBits32( bit_stream_t * p_bit_stream )
 {
-    u32             i_result;
+    uint32_t        i_result;
 
     if( p_bit_stream->fifo.i_available == 32 )
     {
index df7f103644b43270a4270f08898bca785d86a4cf..28be956d178cd063b3c5f22120288d45ec0b7cb3 100644 (file)
@@ -4,7 +4,7 @@
  * control the pace of reading. 
  *****************************************************************************
  * Copyright (C) 1999, 2000 VideoLAN
- * $Id: input_ext-intf.h,v 1.77 2002/08/18 13:16:51 sigmunau Exp $
+ * $Id: input_ext-intf.h,v 1.78 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
  *****************************************************************************/
 struct es_descriptor_t
 {
-    u16                     i_id;            /* stream ID for PS, PID for TS */
-    u8                      i_stream_id;     /* stream ID defined in the PES */
+    uint16_t                i_id;            /* stream ID for PS, PID for TS */
+    uint8_t                 i_stream_id;     /* stream ID defined in the PES */
     vlc_fourcc_t            i_fourcc;                         /* stream type */
-    u8                      i_cat;    /* stream category (audio, video, spu) */
+    uint8_t                 i_cat;    /* stream category (audio, video, spu) */
     int                     i_demux_fd;   /* used to store demux device
                                              file handle */
     char                    psz_desc[20]; /* description of ES: audio language
@@ -93,12 +93,12 @@ struct es_descriptor_t
 struct pgrm_descriptor_t
 {
     /* Program characteristics */
-    u16                     i_number;                      /* program number */
-    u8                      i_version;                     /* version number */
+    uint16_t                i_number;                      /* program number */
+    uint8_t                 i_version;                     /* version number */
     vlc_bool_t              b_is_ok;      /* Is the description up to date ? */
 
     /* Service Descriptor (program name) - DVB extension */
-    u8                      i_srv_type;
+    uint8_t                 i_srv_type;
     char *                  psz_srv_name;
 
     /* Synchronization information */
@@ -208,7 +208,7 @@ struct input_info_category_t {
  *****************************************************************************/
 struct stream_descriptor_t
 {
-    u16                     i_stream_id;                        /* stream id */
+    uint16_t                i_stream_id;                        /* stream id */
     vlc_bool_t              b_changed;    /* if stream has been changed,
                                              we have to inform the interface */
     vlc_mutex_t             stream_lock;  /* to be taken every time you read
@@ -228,7 +228,7 @@ struct stream_descriptor_t
     input_area_t *          p_new_area;  /* Newly selected area from
                                           * the interface */
 
-    u32                     i_mux_rate; /* the rate we read the stream (in
+    uint32_t                i_mux_rate; /* the rate we read the stream (in
                                          * units of 50 bytes/s) ; 0 if undef */
 
     /* New status and rate requested by the interface */
@@ -279,7 +279,7 @@ struct stream_position_t
     off_t    i_tell;     /* actual location in the area (in arbitrary units) */
     off_t    i_size;          /* total size of the area (in arbitrary units) */
 
-    u32      i_mux_rate;                /* the rate we read the stream (in
+    uint32_t i_mux_rate;                /* the rate we read the stream (in
                                          * units of 50 bytes/s) ; 0 if undef */
 };
 
@@ -386,7 +386,7 @@ VLC_EXPORT( void, input_DumpStream, ( input_thread_t * ) );
 VLC_EXPORT( char *, input_OffsetToTime, ( input_thread_t *, char *, off_t ) );
 VLC_EXPORT( int, input_ToggleES, ( input_thread_t *, es_descriptor_t *, vlc_bool_t ) );
 VLC_EXPORT( int, input_ChangeArea, ( input_thread_t *, input_area_t * ) );
-VLC_EXPORT( int, input_ChangeProgram, ( input_thread_t *, u16 ) );
+VLC_EXPORT( int, input_ChangeProgram, ( input_thread_t *, uint16_t ) );
 
 int    input_ToggleGrayscale( input_thread_t * );
 int    input_ToggleMute     ( input_thread_t * );
index 1903f4b3d561bc88f5fe0066a1d1003931b63a5f..464c72df3f16a50e8cfde2a6c79b254de710fc42 100644 (file)
@@ -3,7 +3,7 @@
  *                      but exported to plug-ins
  *****************************************************************************
  * Copyright (C) 1999-2002 VideoLAN
- * $Id: input_ext-plugins.h,v 1.36 2002/10/27 16:58:14 gbazin Exp $
+ * $Id: input_ext-plugins.h,v 1.37 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
  *****************************************************************************/
 VLC_EXPORT( int,  input_InitStream,( input_thread_t *, size_t ) );
 VLC_EXPORT( void, input_EndStream, ( input_thread_t * ) );
-VLC_EXPORT( pgrm_descriptor_t *, input_FindProgram,( input_thread_t *, u16 ) );
-VLC_EXPORT( pgrm_descriptor_t *, input_AddProgram, ( input_thread_t *, u16, size_t ) );
+VLC_EXPORT( pgrm_descriptor_t *, input_FindProgram,( input_thread_t *, uint16_t ) );
+VLC_EXPORT( pgrm_descriptor_t *, input_AddProgram, ( input_thread_t *, uint16_t, size_t ) );
 VLC_EXPORT( void, input_DelProgram,( input_thread_t *, pgrm_descriptor_t * ) );
 VLC_EXPORT( int, input_SetProgram,( input_thread_t *, pgrm_descriptor_t * ) );
 VLC_EXPORT( input_area_t *, input_AddArea,( input_thread_t * ) );
 VLC_EXPORT( void, input_DelArea,   ( input_thread_t *, input_area_t * ) );
-VLC_EXPORT( es_descriptor_t *, input_FindES,( input_thread_t *, u16 ) );
-VLC_EXPORT( es_descriptor_t *, input_AddES, ( input_thread_t *, pgrm_descriptor_t *, u16, size_t ) );
+VLC_EXPORT( es_descriptor_t *, input_FindES,( input_thread_t *, uint16_t ) );
+VLC_EXPORT( es_descriptor_t *, input_AddES, ( input_thread_t *, pgrm_descriptor_t *, uint16_t, size_t ) );
 VLC_EXPORT( void, input_DelES,     ( input_thread_t *, es_descriptor_t * ) );
 VLC_EXPORT( int,  input_SelectES,  ( input_thread_t *, es_descriptor_t * ) );
 VLC_EXPORT( int,  input_UnselectES,( input_thread_t *, es_descriptor_t * ) );
index e4c26ba3de50f06a8ab6110474e773139621b2d8..ad9f43cb1664441ea794eff01ad1eac0177c217d 100644 (file)
@@ -4,7 +4,7 @@
  * interface, such as message output.
  *****************************************************************************
  * Copyright (C) 1999, 2000 VideoLAN
- * $Id: interface.h,v 1.36 2002/10/11 22:32:55 sam Exp $
+ * $Id: interface.h,v 1.37 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *
@@ -62,7 +62,7 @@ VLC_EXPORT( void,              intf_Destroy,    ( intf_thread_t * ) );
 /*****************************************************************************
  * Macros
  *****************************************************************************/
-#ifdef WIN32
+#if defined( WIN32 ) && !defined( UNDER_CE )
 #    define CONSOLE_INTRO_MSG \
          AllocConsole(); \
          freopen( "CONOUT$", "w", stdout ); \
index b274d53bb7867eef91cb13d6949d70a263baa7b2..89b1bc4102fb2ee721b6a23cd79f59c69b404638 100644 (file)
@@ -2,7 +2,7 @@
  * iso_lang.h: function to decode language code (in dvd or a52 for instance).
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: iso_lang.h,v 1.7 2002/07/20 18:01:41 sam Exp $
+ * $Id: iso_lang.h,v 1.8 2002/11/11 14:39:11 sam Exp $
  *
  * Author: Stéphane Borel <stef@via.ecp.fr>
  *         Arnaud de Bossoreille de Ribou <bozo@via.ecp.fr>
@@ -34,5 +34,5 @@ struct iso639_lang_t
 VLC_EXPORT( const iso639_lang_t *, GetLang_1, ( const char * ) );
 VLC_EXPORT( const iso639_lang_t *, GetLang_2T, ( const char * ) );
 VLC_EXPORT( const iso639_lang_t *, GetLang_2B, ( const char * ) );
-VLC_EXPORT( const char *, DecodeLanguage, ( u16 ) );
+VLC_EXPORT( const char *, DecodeLanguage, ( uint16_t ) );
 
index 7f93dc96b1bea472c8f1d2c9994a0cec99bc8775..5e67e90bbaa45e7abd924447f5e77d4be7f54bc3 100644 (file)
@@ -3,7 +3,7 @@
  * Declaration and extern access to global program object.
  *****************************************************************************
  * Copyright (C) 1999, 2000, 2001, 2002 VideoLAN
- * $Id: main.h,v 1.50 2002/11/10 18:04:22 sam Exp $
+ * $Id: main.h,v 1.51 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *
@@ -37,7 +37,7 @@ struct libvlc_t
     vlc_bool_t             b_ready;
 
     /* CPU extensions */
-    u32                    i_cpu;
+    uint32_t               i_cpu;
 
     /* Generic settings */
     int                    i_verbose;                       /* info messages */
@@ -83,7 +83,7 @@ struct vlc_t
 
     /* Fast memcpy plugin used */
     module_t *             p_memcpy_module;
-#if defined( WIN32 )
+#if defined( UNDER_CE )
     void* ( __cdecl *pf_memcpy ) ( void *, const void *, size_t );
     void* ( __cdecl *pf_memset ) ( void *, int, size_t );
 #else
index 67517bc9adba8ea73d603ad2b611c307f8113608..194e1aaa3fc7c11a9dffa7677c5af36b727a086b 100644 (file)
  */
 
 typedef        union {
-       s64                     q;      /* Quadword (64-bit) value */
-       u64                     uq;     /* Unsigned Quadword */
-       s32                     d[2];   /* 2 Doubleword (32-bit) values */
-       u32                     ud[2];  /* 2 Unsigned Doubleword */
-       s16                     w[4];   /* 4 Word (16-bit) values */
-       u16                     uw[4];  /* 4 Unsigned Word */
-       s8                      b[8];   /* 8 Byte (8-bit) values */
-       u8                      ub[8];  /* 8 Unsigned Byte */
+       int64_t                 q;      /* Quadword (64-bit) value */
+       uint64_t                uq;     /* Unsigned Quadword */
+       int32_t                 d[2];   /* 2 Doubleword (32-bit) values */
+       uint32_t                ud[2];  /* 2 Unsigned Doubleword */
+       int16_t                 w[4];   /* 4 Word (16-bit) values */
+       uint16_t                uw[4];  /* 4 Unsigned Word */
+       int8_t                  b[8];   /* 8 Byte (8-bit) values */
+       uint8_t                 ub[8];  /* 8 Unsigned Byte */
        float                   s[2];   /* Single-precision (32-bit) value */
 } ATTR_ALIGN(8) mmx_t; /* On an 8-byte (64-bit) boundary */
 
index 7182d9b14d04d6c4ded46d271009251433c76ebb..01f66d8f6729a931c57194001fe30d42639853d8 100644 (file)
@@ -2,7 +2,7 @@
  * modules.h : Module management functions.
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: modules.h,v 1.61 2002/08/21 17:31:58 sam Exp $
+ * $Id: modules.h,v 1.62 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -67,9 +67,9 @@ struct module_t
 
     char *pp_shortcuts[ MODULE_SHORTCUT_MAX ];    /* Shortcuts to the module */
 
-    char *psz_capability;                                      /* Capability */
-    int   i_score;                              /* Score for each capability */
-    u32   i_cpu;                                /* Required CPU capabilities */
+    char    *psz_capability;                                   /* Capability */
+    int      i_score;                           /* Score for each capability */
+    uint32_t i_cpu;                             /* Required CPU capabilities */
 
     vlc_bool_t b_unloadable;                          /* Can we be dlclosed? */
     vlc_bool_t b_reentrant;                             /* Are we reentrant? */
index 8f779035aa4e557227e9060907148f0ec9ce06d2..b7637237b73cf7ae279071da5d0be945e0160385 100644 (file)
@@ -9,7 +9,7 @@
  * Functions prototyped are implemented in interface/mtime.c.
  *****************************************************************************
  * Copyright (C) 1996, 1997, 1998, 1999, 2000 VideoLAN
- * $Id: mtime.h,v 1.12 2002/06/01 12:31:57 sam Exp $
+ * $Id: mtime.h,v 1.13 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *
@@ -36,7 +36,7 @@
  * returning the date of the first image to be displayed. It can be used in
  * comparaison with other values: all existing dates will be earlier.
  *****************************************************************************/
-#define LAST_MDATE ((mtime_t)((u64)(-1)/2))
+#define LAST_MDATE ((mtime_t)((uint64_t)(-1)/2))
 
 /*****************************************************************************
  * MSTRTIME_MAX_SIZE: maximum possible size of mstrtime
index ae0a4288577ded9d07a5dae471b99e39a4f49068..c9f59aa2fb561f73ac5276b58a55074da200825b 100644 (file)
@@ -2,7 +2,7 @@
  * os_specific.h: OS specific features
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: os_specific.h,v 1.9 2002/06/02 14:26:15 gbazin Exp $
+ * $Id: os_specific.h,v 1.10 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *          Gildas Bazin <gbazin@netcourrier.com>
@@ -30,7 +30,7 @@
 #   include "beos_specific.h"
 #elif defined( SYS_DARWIN )
 #   include "darwin_specific.h"
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
 #   include "win32_specific.h"
 #else
 #   undef _NEED_OS_SPECIFIC_H
index 7deddc1226b6a2062a5973bff50545c578f9cfa8..cb822d4427ad5affe922a75db48c7c4fd7c6990a 100644 (file)
@@ -2,7 +2,7 @@
  * variables.h: variables handling
  *****************************************************************************
  * Copyright (C) 2002 VideoLAN
- * $Id: variables.h,v 1.7 2002/10/28 20:57:01 sam Exp $
+ * $Id: variables.h,v 1.8 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -34,7 +34,7 @@ struct variable_t
 
     /* The variable unique name, (almost) unique hashed value, and type */
     char *       psz_name;
-    u32          i_hash;
+    uint32_t     i_hash;
     int          i_type;
 
     /* A pointer to a comparison function, a duplication function, and
index 5d2fd3e463a4cdfd2ba85a9b89c069c9c542e2e6..be29e9be7e1c9f3ac1654a01b432cf6eb90e8995 100644 (file)
@@ -4,7 +4,7 @@
  * includes all common video types and constants.
  *****************************************************************************
  * Copyright (C) 1999, 2000 VideoLAN
- * $Id: video.h,v 1.57 2002/11/06 18:07:57 sam Exp $
+ * $Id: video.h,v 1.58 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *
@@ -28,7 +28,7 @@
  *****************************************************************************/
 typedef struct plane_t
 {
-    u8 *p_pixels;                               /* Start of the plane's data */
+    uint8_t *p_pixels;                          /* Start of the plane's data */
 
     /* Variables used for fast memcpy operations */
     int i_lines;                                          /* Number of lines */
@@ -55,7 +55,7 @@ struct picture_t
     /* Picture data - data can always be freely modified, but p_data may
      * NEVER be modified. A direct buffer can be handled as the plugin
      * wishes, it can even swap p_pixels buffers. */
-    u8             *p_data;
+    uint8_t        *p_data;
     void           *p_data_orig;                  /* pointer before memalign */
     plane_t         p[ VOUT_MAX_PLANES ];       /* description of the planes */
     int             i_planes;                  /* number of allocated planes */
@@ -109,14 +109,17 @@ struct picture_heap_t
     int i_bmask, i_rbshift, i_lbshift;
 
     /* Stuff used for palettized RGB planes */
-    void (* pf_setpalette) ( vout_thread_t *, u16 *, u16 *, u16 * );
+    void (* pf_setpalette) ( vout_thread_t *, uint16_t *, uint16_t *, uint16_t * );
 };
 
-/* RGB2PIXEL: assemble RGB components to a pixel value, returns a u32 */
-#define RGB2PIXEL( p_vout, i_r, i_g, i_b )                                    \
-    (((((u32)i_r) >> p_vout->output.i_rrshift) << p_vout->output.i_lrshift) | \
-     ((((u32)i_g) >> p_vout->output.i_rgshift) << p_vout->output.i_lgshift) | \
-     ((((u32)i_b) >> p_vout->output.i_rbshift) << p_vout->output.i_lbshift))
+/* RGB2PIXEL: assemble RGB components to a pixel value, returns a uint32_t */
+#define RGB2PIXEL( p_vout, i_r, i_g, i_b )          \
+    (((((uint32_t)i_r) >> p_vout->output.i_rrshift) \
+                       << p_vout->output.i_lrshift) \
+   | ((((uint32_t)i_g) >> p_vout->output.i_rgshift) \
+                       << p_vout->output.i_lgshift) \
+   | ((((uint32_t)i_b) >> p_vout->output.i_rbshift) \
+                       << p_vout->output.i_lbshift))
 
 /*****************************************************************************
  * Flags used to describe the status of a picture
@@ -191,9 +194,9 @@ struct subpicture_t
         {
             vout_font_t *       p_font;            /* font, NULL for default */
             int                 i_style;                       /* text style */
-            u32                 i_char_color;             /* character color */
-            u32                 i_border_color;              /* border color */
-            u32                 i_bg_color;              /* background color */
+            uint32_t            i_char_color;             /* character color */
+            uint32_t            i_border_color;              /* border color */
+            uint32_t            i_bg_color;              /* background color */
         } text;
     } type;
 #endif
index 22e10e7a0707c39c669b4f58bacdec44e15ab820..1d386795543442f1309ee93a49ebe138cdd93591 100644 (file)
@@ -5,7 +5,7 @@
  * thread, and destroy a previously opened video output thread.
  *****************************************************************************
  * Copyright (C) 1999, 2000 VideoLAN
- * $Id: video_output.h,v 1.85 2002/11/06 18:07:57 sam Exp $
+ * $Id: video_output.h,v 1.86 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *          Samuel Hocevar <sam@via.ecp.fr>
@@ -68,7 +68,7 @@ struct vout_thread_t
     vout_sys_t *        p_sys;                       /* system output method */
 
     /* Current display properties */
-    u16                 i_changes;             /* changes made to the thread */
+    uint16_t            i_changes;             /* changes made to the thread */
     float               f_gamma;                                    /* gamma */
     vlc_bool_t          b_grayscale;           /* color or grayscale display */
     vlc_bool_t          b_info;              /* print additional information */
@@ -142,13 +142,13 @@ struct vout_thread_t
  * Prototypes
  *****************************************************************************/
 #define vout_CreateThread(a,b,c,d,e) __vout_CreateThread(VLC_OBJECT(a),b,c,d,e)
-VLC_EXPORT( vout_thread_t *, __vout_CreateThread,   ( vlc_object_t *, int, int, u32, int ) );
+VLC_EXPORT( vout_thread_t *, __vout_CreateThread,   ( vlc_object_t *, int, int, uint32_t, int ) );
 VLC_EXPORT( void,              vout_DestroyThread,  ( vout_thread_t * ) );
 
-VLC_EXPORT( int,             vout_ChromaCmp,      ( u32, u32 ) );
+VLC_EXPORT( int,             vout_ChromaCmp,      ( uint32_t, uint32_t ) );
 
 VLC_EXPORT( picture_t *,     vout_CreatePicture,  ( vout_thread_t *, vlc_bool_t, vlc_bool_t, vlc_bool_t ) );
-VLC_EXPORT( void,            vout_AllocatePicture,( vout_thread_t *, picture_t *, int, int, u32 ) );
+VLC_EXPORT( void,            vout_AllocatePicture,( vout_thread_t *, picture_t *, int, int, uint32_t ) );
 VLC_EXPORT( void,            vout_DestroyPicture, ( vout_thread_t *, picture_t * ) );
 VLC_EXPORT( void,            vout_DisplayPicture, ( vout_thread_t *, picture_t * ) );
 VLC_EXPORT( void,            vout_DatePicture,    ( vout_thread_t *, picture_t *, mtime_t ) );
index d206019c664670c60336beec77d20afa0de188d2..91442dd3272e290d058f6e3093f9b87b061a87aa 100644 (file)
@@ -3,7 +3,7 @@
  * Collection of useful common types and macros definitions
  *****************************************************************************
  * Copyright (C) 1998, 1999, 2000 VideoLAN
- * $Id: vlc_common.h,v 1.36 2002/11/10 23:41:53 sam Exp $
+ * $Id: vlc_common.h,v 1.37 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@via.ecp.fr>
  *          Vincent Seguin <seguin@via.ecp.fr>
@@ -74,7 +74,9 @@
     typedef signed short        int16_t;
     typedef unsigned int        uint32_t;
     typedef signed int          int32_t;
-#   if defined( _MSC_VER ) || ( defined( WIN32 ) && !defined( __MINGW32__ ) )
+#   if defined( _MSC_VER ) \
+      || defined( UNDER_CE ) \
+      || ( defined( WIN32 ) && !defined( __MINGW32__ ) )
     typedef unsigned __int64    uint64_t;
     typedef signed __int64      int64_t;
 #   else
@@ -97,7 +99,7 @@ typedef int                 ptrdiff_t;
 #   endif
 #endif
 
-#if defined( WIN32 )
+#if defined( WIN32 ) || defined( UNDER_CE )
 typedef int                 ssize_t;
 #endif
 
@@ -272,7 +274,7 @@ typedef int ( * vlc_callback_t ) ( vlc_object_t *,      /* variable's object */
 /*****************************************************************************
  * OS-specific headers and thread types
  *****************************************************************************/
-#if defined( WIN32 )
+#if defined( WIN32 ) || defined( UNDER_CE )
 #   define WIN32_LEAN_AND_MEAN
 #   include <windows.h>
 #endif
@@ -334,7 +336,7 @@ typedef int ( * vlc_callback_t ) ( vlc_object_t *,      /* variable's object */
 #ifdef NTOHL_IN_SYS_PARAM_H
 #   include <sys/param.h>
 
-#elif !defined(WIN32) /* NTOHL_IN_SYS_PARAM_H || WIN32 */
+#elif !defined(WIN32) && !defined( UNDER_CE )
 #   include <netinet/in.h>
 
 #endif /* NTOHL_IN_SYS_PARAM_H || WIN32 */
@@ -503,7 +505,7 @@ static inline uint64_t U64_AT( void * _p )
 #endif
 
 /* Format type specifiers for 64 bits numbers */
-#if !defined(WIN32)
+#if !defined(WIN32) && !defined(UNDER_CE)
 #   define I64Fd "%lld"
 #   define I64Fi "%lli"
 #   define I64Fo "%llo"
@@ -517,16 +519,16 @@ static inline uint64_t U64_AT( void * _p )
 #   define I64Fu "%I64u"
 #   define I64Fx "%I64x"
 #   define I64FX "%I64X"
-#endif /* defined(WIN32) */
+#endif /* defined(WIN32)||defined(UNDER_CE) */
 
 /* 64 bits integer constant suffix */
-#if !defined(WIN32)
+#if !defined(WIN32) && !defined(UNDER_CE)
 #   define I64C(x)         x##LL
 #else
 #   define I64C(x)         x##i64
-#endif /* defined(WIN32) */
+#endif /* defined(WIN32)||defined(UNDER_CE) */
 
-#ifdef WIN32
+#if defined(WIN32) && !defined(UNDER_CE)
 /* win32, cl and icl support */
 #   if defined( _MSC_VER ) || !defined( __MINGW32__ )
 #       define __attribute__(x)
index 5b743c6063780f99a2d31beb86e1e02acfcedd46..dfde322fbe67b8375025ba87af6e6b8c88d291a6 100644 (file)
@@ -50,7 +50,7 @@
 /* The configuration file and directory */
 #ifdef SYS_BEOS
 #  define CONFIG_DIR                    "config/settings"
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
 #  define CONFIG_DIR                   "vlc"
 #else
 #  define CONFIG_DIR                    ".vlc"
 #define DEFAULT_PTS_DELAY               (mtime_t)(.3*CLOCK_FREQ)
 
 /* DVD and VCD devices */
-#ifndef WIN32
+#if !defined( WIN32 ) && !defined( UNDER_CE )
 #   define DVD_DEVICE "/dev/dvd"
 #   define VCD_DEVICE "/dev/cdrom"
 #else
index 9610fb6e79f75ede62441dfbb4906ab2439889fe..f3a31c0cbf9b5e89a556f0fbe7843f1a537738cc 100644 (file)
@@ -2,7 +2,7 @@
  * cpu.h: CPU type detection
  *****************************************************************************
  * Copyright (C) 2002 VideoLAN
- * $Id: vlc_cpu.h,v 1.4 2002/10/03 13:21:54 sam Exp $
+ * $Id: vlc_cpu.h,v 1.5 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -21,5 +21,5 @@
  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
  *****************************************************************************/
 
-u32 CPUCapabilities( void );
+uint32_t CPUCapabilities( void );
 
index 4a94093984bb470bdb4c6c5ef9ed8db302aa5d92..255eec6fc605de735065121cb58f32cc591165b8 100644 (file)
@@ -3,7 +3,7 @@
  * This header provides portable declarations for mutexes & conditions
  *****************************************************************************
  * Copyright (C) 1999, 2002 VideoLAN
- * $Id: vlc_threads.h,v 1.17 2002/11/10 18:04:22 sam Exp $
+ * $Id: vlc_threads.h,v 1.18 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Jean-Marc Dressler <polux@via.ecp.fr>
  *          Samuel Hocevar <sam@via.ecp.fr>
 #elif defined( ST_INIT_IN_ST_H )                            /* State threads */
 #   include <st.h>
 
-#elif defined( WIN32 )
-#   if defined( UNDER_CE )
+#elif defined( UNDER_CE )
                                                                 /* WinCE API */
-#   else
-#       include <process.h>                                     /* Win32 API */
-#   endif
+#elif defined( WIN32 )
+#   include <process.h>                                         /* Win32 API */
 
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )  /* pthreads (like Linux & BSD) */
 #   include <pthread.h>
@@ -80,7 +78,7 @@
 #   define VLC_THREAD_PRIORITY_VIDEO 31
 #   define VLC_THREAD_PRIORITY_OUTPUT 31
 
-#elif defined(WIN32)
+#elif defined(WIN32) || defined(UNDER_CE)
 #   define VLC_THREAD_PRIORITY_LOW 0
 #   define VLC_THREAD_PRIORITY_INPUT THREAD_PRIORITY_TIME_CRITICAL
 #   define VLC_THREAD_PRIORITY_AUDIO THREAD_PRIORITY_HIGHEST
@@ -126,7 +124,7 @@ typedef struct
     vlc_object_t * p_this;
 } vlc_cond_t;
 
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
 typedef HANDLE vlc_thread_t;
 typedef BOOL (WINAPI *SIGNALOBJECTANDWAIT) ( HANDLE, HANDLE, DWORD, BOOL );
 typedef unsigned (__stdcall *PTHREAD_START) (void *);
index b2d6213c40f185eaefe6f929a8873a62a5fb5ece..86b81f2f169d633d23b545289605dc71dc178170 100644 (file)
@@ -3,7 +3,7 @@
  * This header provides a portable threads implementation.
  *****************************************************************************
  * Copyright (C) 1999, 2002 VideoLAN
- * $Id: vlc_threads_funcs.h,v 1.8 2002/11/10 18:04:22 sam Exp $
+ * $Id: vlc_threads_funcs.h,v 1.9 2002/11/11 14:39:11 sam Exp $
  *
  * Authors: Jean-Marc Dressler <polux@via.ecp.fr>
  *          Samuel Hocevar <sam@via.ecp.fr>
@@ -76,6 +76,10 @@ static inline int __vlc_mutex_lock( char * psz_file, int i_line,
 #elif defined( ST_INIT_IN_ST_H )
     i_result = st_mutex_lock( p_mutex->mutex );
 
+#elif defined( UNDER_CE )
+    EnterCriticalSection( &p_mutex->csection );
+    return 0;
+
 #elif defined( WIN32 )
     if( p_mutex->mutex )
     {
@@ -143,6 +147,10 @@ static inline int __vlc_mutex_unlock( char * psz_file, int i_line,
 #elif defined( ST_INIT_IN_ST_H )
     i_result = st_mutex_unlock( p_mutex->mutex );
 
+#elif defined( UNDER_CE )
+    LeaveCriticalSection( &p_mutex->csection );
+    return 0;
+
 #elif defined( WIN32 )
     if( p_mutex->mutex )
     {
@@ -224,6 +232,10 @@ static inline int __vlc_cond_signal( char * psz_file, int i_line,
 #elif defined( ST_INIT_IN_ST_H )
     i_result = st_cond_signal( p_condvar->cond );
 
+#elif defined( UNDER_CE )
+    PulseEvent( p_condvar->event );
+    return 0;
+
 #elif defined( WIN32 )
     /* Release one waiting thread if one is available. */
     /* For this trick to work properly, the vlc_cond_signal must be surrounded
@@ -232,7 +244,6 @@ static inline int __vlc_cond_signal( char * psz_file, int i_line,
     {
         PulseEvent( p_condvar->event );
     }
-#   ifndef UNDER_CE
     else if( p_condvar->i_win9x_cv == 1 )
     {
         /* Wait for the gate to be open */
@@ -264,7 +275,6 @@ static inline int __vlc_cond_signal( char * psz_file, int i_line,
             WaitForSingleObject( p_condvar->event, INFINITE );
         }
     }
-#   endif
     return 0;
 
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )
@@ -357,6 +367,16 @@ static inline int __vlc_cond_broadcast( char * psz_file, int i_line,
 #elif defined( ST_INIT_IN_ST_H )
     i_result = st_cond_broadcast( p_condvar->cond );
 
+#elif defined( UNDER_CE )
+    int i;
+
+    /* Release all waiting threads. */
+    for( i = p_condvar->i_waiting_threads; i > 0; i-- )
+    {
+        PulseEvent( p_condvar->event );
+    }
+    return 0;
+
 #elif defined( WIN32 )
     int i;
 
@@ -368,7 +388,6 @@ static inline int __vlc_cond_broadcast( char * psz_file, int i_line,
             PulseEvent( p_condvar->event );
         }
     }
-#   ifndef UNDER_CE
     else if( p_condvar->i_win9x_cv == 1 )
     {
         /* Wait for the gate to be open */
@@ -402,7 +421,6 @@ static inline int __vlc_cond_broadcast( char * psz_file, int i_line,
             WaitForSingleObject( p_condvar->event, INFINITE );
         }
     }
-#   endif
     return 0;
 
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )
@@ -491,6 +509,17 @@ static inline int __vlc_cond_wait( char * psz_file, int i_line,
     i_result = st_cond_wait( p_condvar->cond );
     st_mutex_lock( p_mutex->mutex );
 
+#elif defined( UNDER_CE )
+    p_condvar->i_waiting_threads++;
+    LeaveCriticalSection( &p_mutex->csection );
+    WaitForSingleObject( p_condvar->event, INFINITE );
+    p_condvar->i_waiting_threads--;
+
+    /* Reacquire the mutex before returning. */
+    vlc_mutex_lock( p_mutex );
+
+    return 0;
+
 #elif defined( WIN32 )
     if( !p_condvar->semaphore )
     {
index 0ef479604d2a184a1c541f612266ad502bb962e4..7150101b97bb45dd664eebe2f2b99423b47b858a 100644 (file)
@@ -9,9 +9,9 @@
  * Significantly revised and rewinddir, seekdir and telldir added by Colin
  * Peters <colin@fu.is.saga-u.ac.jp>
  *     
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
  * $Author: sam $
- * $Date: 2002/11/10 23:41:53 $
+ * $Date: 2002/11/11 14:39:12 $
  *
  */
 
@@ -94,7 +94,7 @@ opendir (const CHAR *szPath)
     }
   else
     {
-      /* FIXME: if I wasn't lazy, I'dcheck for overflows here. */
+      /* FIXME: if I wasn't lazy, I'd check for overflows here. */
       sprintf (szFullPath, MAX_PATH, "\\%s", szPath );
     }
 #else
index 3462a3e0ab0ae742295b3500739bc671a1750201..60b0b172a90c118d8d975bcb3cdb6bd493c3d74b 100644 (file)
@@ -81,7 +81,7 @@
 #endif
 #endif
 
-#if defined (WIN32) && !defined (__CYGWIN32__)
+#if defined (WIN32) && !defined (__CYGWIN32__) || defined(UNDER_CE)
 /* It's not Unix, really.  See?  Capital letters.  */
 #include <windows.h>
 #define getpid() GetCurrentProcessId()
index 3e3604cfbcbc1c20d86eee516ef6d015612fd194..25252d818583c538d3e8eec2c15b95eaade23c90 100644 (file)
@@ -4,7 +4,7 @@
  * decoders.
  *****************************************************************************
  * Copyright (C) 1998-2002 VideoLAN
- * $Id: input.c,v 1.214 2002/11/10 18:04:23 sam Exp $
+ * $Id: input.c,v 1.215 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-#   include <sys/stat.h>
-#endif
-#ifdef HAVE_FCNTL_H
-#   include <fcntl.h>
-#endif
-
 #include <string.h>
 
 #ifdef HAVE_SYS_TIMES_H
@@ -388,11 +378,11 @@ static int InitThread( input_thread_t * p_input )
     {
         psz_parser++;
     }
-#ifdef WIN32
+#if defined( WIN32 ) || defined( UNDER_CE )
     if( psz_parser - p_input->psz_source == 1 )
     {
         msg_Warn( p_input, "drive letter %c: found in source string",
-                           p_input->psz_source ) ;
+                           p_input->psz_source[0] ) ;
         psz_parser = "";
     }
 #endif
index 7c4acb6309cdc2b83fe92dba006beca7bdd457ba..1b9f7e2647f2d90efd0f760bcec21abb8d1b330e 100644 (file)
@@ -2,7 +2,7 @@
  * input_clock.c: Clock/System date convertions, stream management
  *****************************************************************************
  * Copyright (C) 1999-2001 VideoLAN
- * $Id: input_clock.c,v 1.33 2002/11/10 18:04:23 sam Exp $
+ * $Id: input_clock.c,v 1.34 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>                                           /* off_t */
-#endif
-
 #include "stream_control.h"
 #include "input_ext-intf.h"
 #include "input_ext-dec.h"
index bb323965c356443f158d608907d1bde797f58a2c..e9c4c1fb6f57fedc22bdb9e8066f563a1b402c7a 100644 (file)
@@ -2,7 +2,7 @@
  * input_dec.c: Functions for the management of decoders
  *****************************************************************************
  * Copyright (C) 1999-2001 VideoLAN
- * $Id: input_dec.c,v 1.50 2002/11/10 18:04:23 sam Exp $
+ * $Id: input_dec.c,v 1.51 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>                                           /* off_t */
-#endif
-
 #include "stream_control.h"
 #include "input_ext-dec.h"
 #include "input_ext-intf.h"
index 454ab584b39e5b489c8a2e863b955690213ecfd6..79037f3dd89ef39ee4faebe7227e8b09cb9a5b1a 100644 (file)
@@ -2,7 +2,7 @@
  * input_ext-dec.c: services to the decoders
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: input_ext-dec.c,v 1.40 2002/11/10 18:04:23 sam Exp $
+ * $Id: input_ext-dec.c,v 1.41 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>                                           /* off_t */
-#endif
-
 #include "stream_control.h"
 #include "input_ext-dec.h"
 #include "input_ext-intf.h"
index 176df15ed0d8a40d6b8f7ae2e240b6f03afddfb9..bf410feef283f5f0506296b842490a6021644472 100644 (file)
@@ -2,7 +2,7 @@
  * input_ext-intf.c: services to the interface
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: input_ext-intf.c,v 1.42 2002/11/10 18:04:23 sam Exp $
+ * $Id: input_ext-intf.c,v 1.43 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>                                           /* off_t */
-#endif
-
 #include "stream_control.h"
 #include "input_ext-dec.h"
 #include "input_ext-intf.h"
index c26270427435f255b027f67365bc46718c1f12fb..d42c348165cae8214fe4907f682d93410d0b9901 100644 (file)
@@ -2,7 +2,7 @@
  * input_ext-plugins.c: useful functions for access and demux plug-ins
  *****************************************************************************
  * Copyright (C) 2001, 2002 VideoLAN
- * $Id: input_ext-plugins.c,v 1.21 2002/11/10 23:41:53 sam Exp $
+ * $Id: input_ext-plugins.c,v 1.22 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -52,7 +52,7 @@
 #endif
 
 #ifdef UNDER_CE
-    /* No network support */
+    /* No network support (FIXME: use winsock1?) */
 #elif defined( WIN32 )
 #   include <winsock2.h>
 #   include <ws2tcpip.h>
index 9ed010096530aaac92bb45c2ba573cf0c9d6fee7..1e7ffe6ce5c3b7982447a3a089fa5038897b5ef2 100644 (file)
@@ -2,7 +2,7 @@
  * input_info.c: Convenient functions to handle the input info structures
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: input_info.c,v 1.8 2002/11/10 18:04:23 sam Exp $
+ * $Id: input_info.c,v 1.9 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Sigmund Augdal <sigmunau@idi.ntnu.no>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>                                           /* off_t */
-#endif
-
 #include "stream_control.h"
 #include "input_ext-intf.h"
 #include "interface.h"
index a14ccc8ec6fd9960d898bb39ee3edc0d1f876c2e..90f855a27db96f3b5a4464bbfcb66075dbb781f2 100644 (file)
@@ -2,7 +2,7 @@
  * input_programs.c: es_descriptor_t, pgrm_descriptor_t management
  *****************************************************************************
  * Copyright (C) 1999-2002 VideoLAN
- * $Id: input_programs.c,v 1.97 2002/11/10 18:04:23 sam Exp $
+ * $Id: input_programs.c,v 1.98 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
 
 #include <vlc/vlc.h>
 
-#ifdef HAVE_SYS_TYPES_H
-#   include <sys/types.h>                                           /* off_t */
-#endif
-
 #include "stream_control.h"
 #include "input_ext-intf.h"
 #include "input_ext-dec.h"
@@ -637,7 +633,7 @@ int input_UnselectES( input_thread_t * p_input, es_descriptor_t * p_es )
             i_index++;
         }
 
-        /* XXX: no need to memmove, we have unordered data */
+        /* XXX: no need to memmove, we have unsorted data */
         REMOVE_ELEM( p_input->stream.pp_selected_es,
                      p_input->stream.i_selected_es_number,
                      i_index );
index 6244e3f064864fa15447f37640ed8a6aa59f7fa0..615808998ab20e2fa742e95525b71c92a351b17e 100644 (file)
@@ -2,7 +2,7 @@
  * intf_eject.c: CD/DVD-ROM ejection handling functions
  *****************************************************************************
  * Copyright (C) 2001, 2002 VideoLAN
- * $Id: intf_eject.c,v 1.16 2002/11/10 18:04:23 sam Exp $
+ * $Id: intf_eject.c,v 1.17 2002/11/11 14:39:12 sam Exp $
  *
  * Author: Julien Blache <jb@technologeek.org> for the Linux part
  *               with code taken from the Linux "eject" command
@@ -154,13 +154,11 @@ int __intf_Eject( vlc_object_t *p_this, const char *psz_device )
 
     return 1;
 
-#elif defined(WIN32)
-
-#if defined(UNDER_CE)
+#elif defined(UNDER_CE)
     msg_Warn( p_this, "CD-Rom ejection unsupported on this platform" );
-    i_ret = -1;
-    
-#else
+    return 1;
+
+#elif defined(WIN32)
     HANDLE h_drive ;
     TCHAR  psz_drive_id[8] ;
     DWORD  dw_access_flags = GENERIC_READ ;
@@ -220,7 +218,6 @@ int __intf_Eject( vlc_object_t *p_this, const char *psz_device )
         CloseHandle (h_drive) ;
         return (i_ret) ;
     }
-#endif /* UNDER_CE */
 
 #else   /* WIN32 */
 
index b1163474e3cb088bee93a505016a86f46eb3f5a3..c39db6b2cd071dfd755a6f156aa65073e20ba3f0 100644 (file)
@@ -2,7 +2,7 @@
  * configuration.c management of the modules configuration
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: configuration.c,v 1.44 2002/11/10 23:41:53 sam Exp $
+ * $Id: configuration.c,v 1.45 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Gildas Bazin <gbazin@netcourrier.com>
  *
@@ -1216,7 +1216,7 @@ char *config_GetHomeDir( void )
     struct passwd *p_pw = NULL;
 #endif
 
-#ifdef WIN32
+#if defined(WIN32) || defined(UNDER_CE)
     typedef HRESULT (WINAPI *SHGETFOLDERPATH)( HWND, int, HANDLE, DWORD,
                                                LPTSTR );
 #   define CSIDL_FLAG_CREATE 0x8000
index 8247674001dfc051a716f3da0e28be5bf698fbcf..c73ba7f42c3db0f888853c16830bfefb24fe3791 100644 (file)
@@ -2,7 +2,7 @@
  * cpu.c: CPU detection code
  *****************************************************************************
  * Copyright (C) 1998-2002 VideoLAN
- * $Id: cpu.c,v 1.8 2002/11/10 18:04:24 sam Exp $
+ * $Id: cpu.c,v 1.9 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *          Christophe Massiot <massiot@via.ecp.fr>
@@ -65,9 +65,9 @@ static char   *psz_capability;
  *****************************************************************************
  * This function is called to list extensions the CPU may have.
  *****************************************************************************/
-u32 CPUCapabilities( void )
+uint32_t CPUCapabilities( void )
 {
-    volatile u32 i_capabilities = CPU_CAPABILITY_NONE;
+    volatile uint32_t i_capabilities = CPU_CAPABILITY_NONE;
 
 #if defined( SYS_DARWIN )
     struct host_basic_info hi;
index 228252bfc3ebe30f910c4a9633d83aab6eec0469..8cbdf377fc55898bfe019ce6bd4aa94cd767b374 100644 (file)
@@ -4,7 +4,7 @@
  * modules, especially intf modules. See config.h for output configuration.
  *****************************************************************************
  * Copyright (C) 1998-2002 VideoLAN
- * $Id: messages.c,v 1.21 2002/11/10 18:04:24 sam Exp $
+ * $Id: messages.c,v 1.22 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *          Samuel Hocevar <sam@zoy.org>
@@ -454,7 +454,7 @@ static void PrintMsg ( vlc_object_t * p_this, msg_item_t * p_item )
                          p_item->psz_msg );
     }
 
-#if defined(WIN32)
+#if defined(WIN32) || defined(UNDER_CE)
     fflush( stderr );
 #endif
 }
index 872664d31e67a6fef0ce462482aa88e0b6b956a7..7483523b7c72b862c4a62500e30b958a7ecc82f2 100644 (file)
@@ -2,7 +2,7 @@
  * modules.c : Builtin and plugin modules management functions
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: modules.c,v 1.102 2002/11/10 18:04:24 sam Exp $
+ * $Id: modules.c,v 1.103 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *          Ethan C. Baldridge <BaldridgeE@cadmus.com>
@@ -57,6 +57,8 @@
 #elif defined(HAVE_IMAGE_H)                                          /* BeOS */
 #   include <image.h>
 #   define HAVE_DYNAMIC_PLUGINS
+#elif defined(UNDER_CE)
+#   define HAVE_DYNAMIC_PLUGINS
 #elif defined(WIN32)
 #   define HAVE_DYNAMIC_PLUGINS
 #else
index 8d16a59934a8a901f3f815a3af98e730a107f2e0..05a9676a709d8decb74c779dc7cdf75ed19ef7ab 100644 (file)
@@ -2,7 +2,7 @@
  * modules_plugin.h : Plugin management functions used by the core application.
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: modules_plugin.h.in,v 1.5 2002/10/31 11:16:30 sam Exp $
+ * $Id: modules_plugin.h.in,v 1.6 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -37,7 +37,7 @@ static int module_load( const char * psz_filename, module_handle_t * handle )
     *handle = load_add_on( psz_filename );
     return( *handle < 0 );
 
-#elif defined(WIN32)
+#elif defined(WIN32) || defined(UNDER_CE)
     *handle = LoadLibrary( psz_filename );
     return( *handle == NULL ); 
 
@@ -74,7 +74,7 @@ static void module_unload( module_handle_t handle )
 #ifdef SYS_BEOS
     unload_add_on( handle );
 
-#elif defined(WIN32)
+#elif defined(WIN32) || defined(UNDER_CE)
     FreeLibrary( handle );
 
 #else
@@ -106,7 +106,7 @@ static void * _module_getsymbol( module_handle_t handle,
         return( NULL );
     }
 
-#elif defined(WIN32)
+#elif defined(WIN32) || defined(UNDER_CE)
     return( (void *)GetProcAddress( handle, psz_function ) );
 
 #else
@@ -149,7 +149,7 @@ static const char * module_error( char *psz_buffer )
 #if defined(SYS_BEOS)
     return( "failed" );
 
-#elif defined(WIN32)
+#elif defined(WIN32) || defined(UNDER_CE)
     int i, i_error = GetLastError();
 
     FormatMessage( FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
index f084941f89676e824bf59dc23d47c51790006bd6..6dfa582c1ed2e0a15398e80f2f2db1c81975d61f 100644 (file)
@@ -3,7 +3,7 @@
  * Functions are prototyped in mtime.h.
  *****************************************************************************
  * Copyright (C) 1998-2001 VideoLAN
- * $Id: mtime.c,v 1.34 2002/08/08 00:35:11 sam Exp $
+ * $Id: mtime.c,v 1.35 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *
@@ -46,7 +46,7 @@
 #   include <kernel/OS.h>
 #endif
 
-#if defined( WIN32 )
+#if defined( WIN32 ) || defined( UNDER_CE )
 #   include <windows.h>
 #else
 #   include <sys/time.h>
@@ -95,7 +95,7 @@ mtime_t mdate( void )
 #if defined( HAVE_KERNEL_OS_H )
     return( real_time_clock_usecs() );
 
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
     /* We don't get the real date, just the value of a high precision timer.
      * this is because the usual time functions have at best only a milisecond
      * resolution */
@@ -142,7 +142,7 @@ void mwait( mtime_t date )
     }
     snooze( delay );
 
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
     mtime_t usec_time, delay;
 
     usec_time = mdate();
@@ -218,7 +218,7 @@ void msleep( mtime_t delay )
 #elif defined( ST_INIT_IN_ST_H )
     st_usleep( delay );
 
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
     Sleep( (int) (delay / 1000) );
 
 #elif defined( HAVE_NANOSLEEP )
index 26a7f5302f76bbae7c8cbed8a451d7aafae5edee..e539514dcf86b5f7b0ed81b02b6f9776457d7b95 100644 (file)
@@ -2,7 +2,7 @@
  * netutils.c: various network functions
  *****************************************************************************
  * Copyright (C) 1999-2001 VideoLAN
- * $Id: netutils.c,v 1.75 2002/11/10 18:04:24 sam Exp $
+ * $Id: netutils.c,v 1.76 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *          Benoit Steiner <benny@via.ecp.fr>
@@ -50,7 +50,7 @@
 #endif
 
 #if defined( UNDER_CE )
-    /* No real network support */
+    /* No real network support (FIXME: use winsock1?) */
 #elif defined( WIN32 )
 #   include <winsock2.h>
 #else
index 68d556414fc94272c2a1446be9d3bf4b266e635e..cc130d1744f9f9e4bfecd8bf494f33e9a9789810 100644 (file)
@@ -2,7 +2,7 @@
  * threads.c : threads implementation for the VideoLAN client
  *****************************************************************************
  * Copyright (C) 1999, 2000, 2001, 2002 VideoLAN
- * $Id: threads.c,v 1.25 2002/11/10 23:41:53 sam Exp $
+ * $Id: threads.c,v 1.26 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Jean-Marc Dressler <polux@via.ecp.fr>
  *          Samuel Hocevar <sam@zoy.org>
@@ -39,6 +39,7 @@ static volatile int i_initializations = 0;
 
 #if defined( PTH_INIT_IN_PTH_H )
 #elif defined( ST_INIT_IN_ST_H )
+#elif defined( UNDER_CE )
 #elif defined( WIN32 )
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )
     static pthread_mutex_t once_mutex = PTHREAD_MUTEX_INITIALIZER;
@@ -151,6 +152,8 @@ int __vlc_threads_init( vlc_object_t *p_this )
     while( i_status == VLC_THREADS_PENDING ) msleep( THREAD_SLEEP );
 #elif defined( ST_INIT_IN_ST_H )
     while( i_status == VLC_THREADS_PENDING ) msleep( THREAD_SLEEP );
+#elif defined( UNDER_CE )
+    while( i_status == VLC_THREADS_PENDING ) msleep( THREAD_SLEEP );
 #elif defined( WIN32 )
     while( i_status == VLC_THREADS_PENDING ) msleep( THREAD_SLEEP );
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )
@@ -187,6 +190,9 @@ int __vlc_threads_end( vlc_object_t *p_this )
 #elif defined( ST_INIT_IN_ST_H )
     i_initializations--;
 
+#elif defined( UNDER_CE )
+    i_initializations--;
+
 #elif defined( WIN32 )
     i_initializations--;
 
@@ -212,7 +218,7 @@ int __vlc_threads_end( vlc_object_t *p_this )
 /* Wrapper function for profiling */
 static void *      vlc_thread_wrapper ( void *p_wrapper );
 
-#   ifdef WIN32
+#   if defined( WIN32 ) && !defined( UNDER_CE )
 
 #       define ITIMER_REAL 1
 #       define ITIMER_PROF 2
@@ -224,7 +230,7 @@ struct itimerval
 };  
 
 int setitimer(int kind, const struct itimerval* itnew, struct itimerval* itold);
-#   endif /* WIN32 */
+#   endif /* WIN32 && !UNDER_CE */
 
 typedef struct wrapper_t
 {
@@ -257,12 +263,15 @@ int __vlc_mutex_init( vlc_object_t *p_this, vlc_mutex_t *p_mutex )
     p_mutex->mutex = st_mutex_new();
     return ( p_mutex->mutex == NULL ) ? errno : 0;
 
+#elif defined( UNDER_CE )
+    InitializeCriticalSection( &p_mutex->csection );
+    return 0;
+
 #elif defined( WIN32 )
     /* We use mutexes on WinNT/2K/XP because we can use the SignalObjectAndWait
      * function and have a 100% correct vlc_cond_wait() implementation.
      * As this function is not available on Win9x, we can use the faster
      * CriticalSections */
-#   if !defined( UNDER_CE )
     if( p_this->p_libvlc->SignalObjectAndWait &&
         !p_this->p_libvlc->b_fast_mutex )
     {
@@ -271,7 +280,6 @@ int __vlc_mutex_init( vlc_object_t *p_this, vlc_mutex_t *p_mutex )
         return ( p_mutex->mutex != NULL ? 0 : 1 );
     }
     else
-#   endif
     {
         p_mutex->mutex = NULL;
         InitializeCriticalSection( &p_mutex->csection );
@@ -338,6 +346,10 @@ int __vlc_mutex_destroy( char * psz_file, int i_line, vlc_mutex_t *p_mutex )
 #elif defined( ST_INIT_IN_ST_H )
     i_result = st_mutex_destroy( p_mutex->mutex );
 
+#elif defined( UNDER_CE )
+    DeleteCriticalSection( &p_mutex->csection );
+    return 0;
+
 #elif defined( WIN32 )
     if( p_mutex->mutex )
     {
@@ -393,11 +405,21 @@ int __vlc_cond_init( vlc_object_t *p_this, vlc_cond_t *p_condvar )
     p_condvar->cond = st_cond_new();
     return ( p_condvar->cond == NULL ) ? errno : 0;
 
+#elif defined( UNDER_CE )
+    /* Initialize counter */
+    p_condvar->i_waiting_threads = 0;
+
+    /* Create an auto-reset event. */
+    p_condvar->event = CreateEvent( NULL,   /* no security */
+                                    FALSE,  /* auto-reset event */
+                                    FALSE,  /* start non-signaled */
+                                    NULL ); /* unnamed */
+    return !p_condvar->event;
+
 #elif defined( WIN32 )
     /* Initialize counter */
     p_condvar->i_waiting_threads = 0;
 
-#   if !defined( UNDER_CE )
     /* Misc init */
     p_condvar->i_win9x_cv = p_this->p_libvlc->i_win9x_cv;
     p_condvar->SignalObjectAndWait = p_this->p_libvlc->SignalObjectAndWait;
@@ -405,7 +427,6 @@ int __vlc_cond_init( vlc_object_t *p_this, vlc_cond_t *p_condvar )
     if( (p_condvar->SignalObjectAndWait && !p_this->p_libvlc->b_fast_mutex)
         || p_condvar->i_win9x_cv == 0 )
     {
-#   endif
         /* Create an auto-reset event. */
         p_condvar->event = CreateEvent( NULL,   /* no security */
                                         FALSE,  /* auto-reset event */
@@ -414,7 +435,6 @@ int __vlc_cond_init( vlc_object_t *p_this, vlc_cond_t *p_condvar )
 
         p_condvar->semaphore = NULL;
         return !p_condvar->event;
-#   if !defined( UNDER_CE )
     }
     else
     {
@@ -434,7 +454,6 @@ int __vlc_cond_init( vlc_object_t *p_this, vlc_cond_t *p_condvar )
 
         return !p_condvar->semaphore || !p_condvar->event;
     }
-#   endif
 
 #elif defined( PTHREAD_COND_T_IN_PTHREAD_H )
     return pthread_cond_init( &p_condvar->cond, NULL );
@@ -481,6 +500,9 @@ int __vlc_cond_destroy( char * psz_file, int i_line, vlc_cond_t *p_condvar )
 #elif defined( ST_INIT_IN_ST_H )
     i_result = st_cond_destroy( p_condvar->cond );
 
+#elif defined( UNDER_CE )
+    i_result = !CloseHandle( p_condvar->event );
+
 #elif defined( WIN32 )
     if( !p_condvar->semaphore )
         i_result = !CloseHandle( p_condvar->event );
@@ -552,7 +574,7 @@ int __vlc_thread_create( vlc_object_t *p_this, char * psz_file, int i_line,
     p_this->thread_id = st_thread_create( func, (void *)p_this, 1, 0 );
     i_ret = 0;
     
-#elif defined( WIN32 )
+#elif defined( WIN32 ) || defined( UNDER_CE )
     {
         unsigned threadID;
         /* When using the MSVCRT C library you have to use the _beginthreadex
@@ -671,6 +693,9 @@ void __vlc_thread_join( vlc_object_t *p_this, char * psz_file, int i_line )
 #elif defined( ST_INIT_IN_ST_H )
     i_ret = st_thread_join( p_this->thread_id, NULL );
     
+#elif defined( UNDER_CE )
+    WaitForSingleObject( p_this->thread_id, INFINITE );
+
 #elif defined( WIN32 )
     WaitForSingleObject( p_this->thread_id, INFINITE );
 
index 07319c27a577c6d2fa3a545c61519b82165c393b..21bfd720c12b7ac6c7f6b1ef8a6409791995c628 100644 (file)
@@ -2,7 +2,7 @@
  * stream_output.c : stream output module
  *****************************************************************************
  * Copyright (C) 2002 VideoLAN
- * $Id: stream_output.c,v 1.4 2002/11/10 18:04:24 sam Exp $
+ * $Id: stream_output.c,v 1.5 2002/11/11 14:39:12 sam Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -77,7 +77,7 @@ static int InitInstance( sout_instance_t * p_sout )
     {
         psz_parser++;
     }
-#ifdef WIN32
+#if defined( WIN32 ) || defined( UNDER_CE )
     if( psz_parser - p_sout->psz_dest == 1 )
     {
         msg_Warn( p_sout, "drive letter %c: found in source string",