Wireshark mailing list archives

No error when plugin failed to load


From: Maarten Bezemer <maarten.bezemer () gmail com>
Date: Thu, 27 Nov 2014 11:58:04 +0100

Hello,

I am developing a plugin (dissector) for wireshark and I got stuck at some
point.
My plugin was (after a change) not loading for some reason, but I did not
get
any message about this (or the actual reason).

After delving in the wireshark code I stumbled upon wsutil/plugins.c
This piece of code is responsible for (loading) plugins, and should show an
error dialog when loading failed:

report_failure("Couldn't load module %s: %s", filename,
                               g_module_error());

This error (dialog) is not showed in the (QT) UI...
I added

g_log(NULL, G_LOG_LEVEL_WARNING, "Couldn't load module %s: %s",
                               filename, g_module_error());

and the (g_module_)error is shown on the command line.

I was planning to send this change as a patch, but I was wondering what
went
wrong with the original report_failure()..?

 * Is the UI not yet initialized when the plugins are loaded, so the
failure is (silently) ignored?
 * It failure reporting broken in (QT) UI?
 * Something else?

Does anyone has thoughts about this? So a proper patch can be submitted.
If not, I can fire up gdb, so see what is happening, but take takes (quite
some) time, which might unnecessary depending on the thoughts people might
have on this subject.

For now I know the problem with my plugin, so I can continue with its
development.

Regards,
  Maarten
___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev () wireshark org>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request () wireshark org?subject=unsubscribe

Current thread: