]> git.sesse.net Git - vlc/commitdiff
Protects internal headers against incorrect/multiple inclusions
authorRémi Denis-Courmont <rem@videolan.org>
Sat, 20 Oct 2007 13:39:41 +0000 (13:39 +0000)
committerRémi Denis-Courmont <rem@videolan.org>
Sat, 20 Oct 2007 13:39:41 +0000 (13:39 +0000)
src/audio_output/aout_internal.h
src/input/input_internal.h
src/input/vlm_internal.h
src/interface/interface.h
src/misc/variables.h
src/modules/configuration.h
src/modules/modules.h
src/playlist/playlist_internal.h
src/stream_output/stream_output.h

index 2f5244e487b9c2aabbcc75bc8ae2ea59991ee859..a730b92f470b76c911f7435ef4355e7e5ce7440a 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
+#ifndef __LIBVLC_AOUT_INTERNAL_H
+# define __LIBVLC_AOUT_INTERNAL_H 1
+
 #if defined( __APPLE__ ) || defined( SYS_BSD )
 #undef HAVE_ALLOCA
 #endif
@@ -131,3 +138,4 @@ aout_buffer_t * aout_DecNewBuffer( aout_instance_t *, aout_input_t *, size_t );
 void aout_DecDeleteBuffer( aout_instance_t *, aout_input_t *, aout_buffer_t * );
 int aout_DecPlay( aout_instance_t *, aout_input_t *, aout_buffer_t *, int i_input_rate );
 
+#endif /* !__LIBVLC_AOUT_INTERNAL_H */
index 06ee78cc0c22ae1bf936f1175d4225ec2f0ce73b..d2a64131f5f0b7472bdf3c805bdd838206395477 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
 #ifndef _INPUT_INTERNAL_H
 #define _INPUT_INTERNAL_H 1
 
@@ -357,9 +361,6 @@ static inline int demux2_Control( demux_t *p_demux, int i_query, ... )
     return i_result;
 }
 
-#if defined(__PLUGIN__) || defined(__BUILTIN__)
-# warning This is an internal header, something is wrong if you see this message.
-#else
 /* Stream */
 /**
  * stream_t definition
@@ -389,6 +390,5 @@ static inline stream_t *vlc_stream_create( vlc_object_t *obj )
     return (stream_t *)vlc_custom_create( obj, sizeof(stream_t),
                                           VLC_OBJECT_STREAM, "stream" );
 }
-#endif
 
 #endif
index 4896e52c797832af272ab4512343ddfcd3836b03..8609215d0a3f58ca160be656b02c553780d5b4f7 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
 #ifndef _VLM_INTERNAL_H
 #define _VLM_INTERNAL_H 1
 
index cbad578d046c816c01bedff471c4cd73d80b1566..7f9268cbcafca09dac8afbf78a139bc904e202d2 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
+#ifndef __LIBVLC_INTERFACE_H
+# define __LIBVLC_INTERFACE_H 1
+
 /**********************************************************************
  * Interaction
  **********************************************************************/
 
 void intf_InteractionManage( playlist_t *);
 void intf_InteractionDestroy( interaction_t *);
+#endif
index 267985c6d40ab819d41ed2e18b85eb9474ba1131..2565edb88e43d2ed5ce54656c5dbf03850f5a6ff 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
+#ifndef __LIBVLC_VARIABLES_H
+# define __LIBVLC_VARIABLES_H 1
 
 typedef struct callback_entry_t callback_entry_t;
 
@@ -69,4 +75,4 @@ struct variable_t
     /** Array of registered callbacks */
     callback_entry_t * p_entries;
 };
-
+#endif
index 077d49c3f571f88f6eac26981d21b493a63fb7f3..038d65f70bd55a228f1c5d11447d295a64a93f3e 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
 #ifndef LIBVLC_CONFIGURATION_H
 # define LIBVLC_CONFIGURATION_H 1
 
index c28fccb5883ca2b126cacc1ee6f23f4a9af6d77b..0af3ef231eeb7f76deab868239a942d7bdccb885 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
+#ifndef __LIBVLC_MODULES_H
+# define __LIBVLC_MODULES_H 1
+
+
 /* Number of tries before we unload an unused module */
 #define MODULE_HIDE_DELAY 50
 
@@ -152,3 +160,5 @@ void  __module_LoadPlugins     ( vlc_object_t * );
 void  __module_EndBank         ( vlc_object_t * );
 #define module_ResetBank(a)    __module_ResetBank(VLC_OBJECT(a))
 void  __module_ResetBank       ( vlc_object_t * );
+
+#endif /* !__LIBVLC_MODULES_H */
index e82b677ee5eb31d54ff736fafc16c4e7657c5e78..40e1ea3643b47b378d80d9f99f4138c0420a1c63 100644 (file)
@@ -22,6 +22,9 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
+#ifndef __LIBVLC_PLAYLIST_INTERNAL_H
+# define __LIBVLC_PLAYLIST_INTERNAL_H 1
+
 /**
  *  \file
  *  This file contain internal structures and function prototypes related
@@ -130,3 +133,4 @@ int playlist_ItemDelete ( playlist_item_t * );
 #endif
 
 #define PLI_NAME( p ) p && p->p_input ? p->p_input->psz_name : "null"
+#endif /* !__LIBVLC_PLAYLIST_INTERNAL_H */
index d91db30f47c0a4b2c79423780c2b6cf0f95bf712..e153cea494559b7238a2ab619803d9d911e2fd77 100644 (file)
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  ***************************************************************************/
 
+#if defined(__PLUGIN__) || defined(__BUILTIN__) || !defined(__LIBVLC__)
+# error This header file can only be included from LibVLC.
+#endif
+
 #ifndef VLC_SRC_STREAMOUT_H
 # define VLC_SRC_STREAMOUT_H 1