[vlc-commits] Assume we ahve setenv() and unsetenv()

Rémi Denis-Courmont git at videolan.org
Sat Feb 12 21:35:32 CET 2011


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Feb 12 22:34:54 2011 +0200| [5eff95a00506e315d875cb5a2ff70f8bc17b7d9b] | committer: Rémi Denis-Courmont

Assume we ahve setenv() and unsetenv()

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5eff95a00506e315d875cb5a2ff70f8bc17b7d9b
---

 bin/vlc.c |   10 ++++------
 1 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/bin/vlc.c b/bin/vlc.c
index 4299bdf..75a97a1 100644
--- a/bin/vlc.c
+++ b/bin/vlc.c
@@ -91,24 +91,22 @@ int main( int i_argc, const char *ppsz_argv[] )
     /* Restore SIGCHLD in case our parent process ignores it. */
     signal (SIGCHLD, SIG_DFL);
 
-#ifdef HAVE_SETENV
-# ifndef NDEBUG
+#ifndef NDEBUG
     /* Activate malloc checking routines to detect heap corruptions. */
     setenv ("MALLOC_CHECK_", "2", 1);
 
     /* Disable the ugly Gnome crash dialog so that we properly segfault */
     setenv ("GNOME_DISABLE_CRASH_DIALOG", "1", 1);
-# endif
+#endif
 
-# ifdef TOP_BUILDDIR
+#ifdef TOP_BUILDDIR
     setenv ("VLC_PLUGIN_PATH", TOP_BUILDDIR"/modules", 1);
-# endif
+#endif
 
     /* Clear the X.Org startup notification ID. Otherwise the UI might try to
      * change the environment while the process is multi-threaded. That could
      * crash. Screw you X.Org. Next time write a thread-safe specification. */
     unsetenv ("DESKTOP_STARTUP_ID");
-#endif
 
 #ifndef ALLOW_RUN_AS_ROOT
     if (geteuid () == 0)



More information about the vlc-commits mailing list