[PATCH v2 13/14] Log in LoaderUnload() in a signal safe manner

Chase Douglas chase.douglas at canonical.com
Mon Apr 9 11:17:39 PDT 2012


The function may be called from a fatal signal handler.

Signed-off-by: Chase Douglas <chase.douglas at canonical.com>
---
 hw/xfree86/loader/loader.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/hw/xfree86/loader/loader.c b/hw/xfree86/loader/loader.c
index b72b8b8..45e22b4 100644
--- a/hw/xfree86/loader/loader.c
+++ b/hw/xfree86/loader/loader.c
@@ -163,7 +163,9 @@ LoaderSymbol(const char *name)
 void
 LoaderUnload(const char *name, void *handle)
 {
-    xf86Msg(X_INFO, "Unloading %s\n", name);
+    LogMessageVerbSigSafe(X_INFO, 1, "Unloading ");
+    LogMessageVerbSigSafe(X_NONE, 1, name);
+    LogMessageVerbSigSafe(X_NONE, 1, "\n");
     if (handle)
         dlclose(handle);
 }
-- 
1.7.9.1



More information about the xorg-devel mailing list