[pulseaudio-discuss] [PATCH] module: Don't print possibly incorrect message

Tanu Kaskinen tanuk at iki.fi
Mon Mar 11 11:18:38 PDT 2013


BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=61800
---
 src/daemon/ltdl-bind-now.c |    1 +
 src/pulsecore/module.c     |    9 ++++++++-
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/src/daemon/ltdl-bind-now.c b/src/daemon/ltdl-bind-now.c
index cab0405..6fd66e9 100644
--- a/src/daemon/ltdl-bind-now.c
+++ b/src/daemon/ltdl-bind-now.c
@@ -74,6 +74,7 @@ static lt_module bind_now_open(lt_user_data d, const char *fname, lt_dladvise ad
     pa_assert(fname);
 
     if (!(m = dlopen(fname, PA_BIND_NOW))) {
+        pa_log(_("Failed to open module %s: %s"), fname, dlerror());
         lt_dlseterror(LT_ERROR_CANNOT_OPEN);
         return NULL;
     }
diff --git a/src/pulsecore/module.c b/src/pulsecore/module.c
index 47bcd3f..07dddea 100644
--- a/src/pulsecore/module.c
+++ b/src/pulsecore/module.c
@@ -66,7 +66,14 @@ pa_module* pa_module_load(pa_core *c, const char *name, const char *argument) {
     m->proplist = pa_proplist_new();
 
     if (!(m->dl = lt_dlopenext(name))) {
-        pa_log("Failed to open module \"%s\": %s", name, lt_dlerror());
+        /* We used to print the error that is returned by lt_dlerror(), but it
+         * was reported that the error message was sometimes incorrect ("file
+         * not found" when the file did exist). No message is better than an
+         * incorrect message. It would be nice to find and fix the real bug
+         * that caused the incorrect message, but that would require someone
+         * who is able to reproduce the bug to investigate the it more deeply.
+         * https://bugs.freedesktop.org/show_bug.cgi?id=61800 */
+        pa_log("Failed to open module \"%s\".", name);
         goto fail;
     }
 
-- 
1.7.10.4



More information about the pulseaudio-discuss mailing list