]> git.sesse.net Git - vlc/commitdiff
* libvlc.c : Win32 compilation fix.
authorXavier Marchesini <xav@videolan.org>
Wed, 21 Aug 2002 09:26:53 +0000 (09:26 +0000)
committerXavier Marchesini <xav@videolan.org>
Wed, 21 Aug 2002 09:26:53 +0000 (09:26 +0000)
* modules.c : we now check the directory plugins/ to find some plugins.
(this will allow us to use the packager / installer which wasn't aware
of plugins -> modules :)

src/libvlc.c
src/misc/modules.c

index 2ba86c994b1b6d9235f75446d3ceb008fc992f0d..9d87cf6c8b950d227ce2579950028074a8c20ac4 100644 (file)
@@ -2,7 +2,7 @@
  * libvlc.c: main libvlc source
  *****************************************************************************
  * Copyright (C) 1998-2002 VideoLAN
- * $Id: libvlc.c,v 1.29 2002/08/20 18:08:51 sam Exp $
+ * $Id: libvlc.c,v 1.30 2002/08/21 09:26:53 xav Exp $
  *
  * Authors: Vincent Seguin <seguin@via.ecp.fr>
  *          Samuel Hocevar <sam@zoy.org>
 #   include <io.h>
 #endif
 
+#ifdef WIN32                       /* optind, getopt(), included in unistd.h */
+#   include "GNUgetopt/getopt.h"
+#endif
+
 #ifdef HAVE_LOCALE_H
 #   include <locale.h>
 #endif
index e87c55ebadde78aae2c59d9b66a8831b83ac09b1..f29fd90f6015c2cdbd593f849fbf9b0b246a5bb5 100644 (file)
@@ -2,7 +2,7 @@
  * modules.c : Builtin and plugin modules management functions
  *****************************************************************************
  * Copyright (C) 2001 VideoLAN
- * $Id: modules.c,v 1.89 2002/08/20 18:25:42 sam Exp $
+ * $Id: modules.c,v 1.90 2002/08/21 09:26:53 xav Exp $
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *          Ethan C. Baldridge <BaldridgeE@cadmus.com>
@@ -526,7 +526,8 @@ void __module_Unneed( vlc_object_t * p_this, module_t * p_module )
 static void AllocateAllPlugins( vlc_object_t *p_this )
 {
     /* Yes, there are two NULLs because we replace one with "plugin-path". */
-    char *          path[] = { "modules", PLUGIN_PATH, NULL, NULL };
+    char *          path[] = { "modules", PLUGIN_PATH, "plugins", NULL,
+                               NULL };
 
     char **         ppsz_path = path;
     char *          psz_fullpath;
@@ -537,7 +538,7 @@ static void AllocateAllPlugins( vlc_object_t *p_this )
 #endif
 
     /* If the user provided a plugin path, we add it to the list */
-    path[ sizeof(path)/sizeof(char*) - 2 ] = config_GetPsz( p_this,
+    path[ sizeof(path)/sizeof(char*) - 1 ] = config_GetPsz( p_this,
                                                             "plugin-path" );
 
     for( ; *ppsz_path != NULL ; ppsz_path++ )