[vlc-commits] commit: Always call _exit() at end to avoid buggy exit handlers ( Rémi Denis-Courmont )

git at videolan.org git at videolan.org
Sun Aug 8 22:07:54 CEST 2010


vlc/vlc-1.1 | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Aug  8 23:07:47 2010 +0300| [8918cf7802951308af497943cdae3f16999f486f] | committer: Rémi Denis-Courmont 

Always call _exit() at end to avoid buggy exit handlers

Removes the KDE scheduler hack.
(cherry picked from commit 725cf4eb04ab02491301a83d8ce6a5c3f5d80794)

Conflicts:

	bin/vlc.c

> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=8918cf7802951308af497943cdae3f16999f486f
---

 bin/override.c |   10 ----------
 bin/vlc.c      |    5 ++++-
 2 files changed, 4 insertions(+), 11 deletions(-)

diff --git a/bin/override.c b/bin/override.c
index 5e72918..524213b 100644
--- a/bin/override.c
+++ b/bin/override.c
@@ -292,16 +292,6 @@ int (*XSetIOErrorHandler (int (*handler) (Display *))) (Display *)
 }
 #endif
 
-/*** Buggy shared objects ***/
-#include <string.h>
-
-void *dlopen (const char *path, int flag)
-{
-    if (path && strstr (path, "/gui_platform/libkde.so"))
-        return NULL; /* Oh no, not that one! */
-    return CALL(dlopen, path, flag);
-}
-
 #else
 void vlc_enable_override (void)
 {
diff --git a/bin/vlc.c b/bin/vlc.c
index 51633b2..9b580e1 100644
--- a/bin/vlc.c
+++ b/bin/vlc.c
@@ -200,5 +200,8 @@ int main( int i_argc, const char *ppsz_argv[] )
     for (int i = 1; i < argc; i++)
         LocaleFree (argv[i]);
 
-    return 0;
+    /* Do not run exit handlers. Some of them are buggy (e.g. KDE IO scheduler)
+     * and crash. Also some will crash because their library may be already
+     * unloaded (dlclose()). */
+    _exit (0);
 }



More information about the vlc-commits mailing list