--- a/perl5/gplugin-perl5-loader.c Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/gplugin-perl5-loader.c Mon Oct 04 00:14:59 2021 -0500
@@ -28,7 +28,7 @@
static PerlInterpreter *my_perl = NULL;
@@ -161,10 +161,15 @@
perl_parse(interpreter, gplugin_perl_loader_xs_init, argc, argv, NULL);
const gchar *errmsg = "unknown error";
- errmsg = SvPVutf8_nolen(ERRSV);
+ /* ERRSV is a macro so we need to store its returned value so we don't + * call it multiple times. + errmsg = SvPVutf8_nolen(err_tmp); g_set_error_literal(error, GPLUGIN_DOMAIN, 0, errmsg);
@@ -177,10 +182,15 @@
ret = perl_run(interpreter);
const gchar *errmsg = "unknown error";
- errmsg = SvPVutf8_nolen(ERRSV);
+ /* ERRSV is a macro so we need to store its returned value so we don't + * call it multiple times. + errmsg = SvPVutf8_nolen(err_tmp); g_set_error_literal(error, GPLUGIN_DOMAIN, 0, errmsg);
@@ -193,6 +203,9 @@
info = gplugin_perl_loader_call_gplugin_query(interpreter, error);
if(!GPLUGIN_IS_PLUGIN_INFO(info)) {
+ /* If the plugin's query method didn't set error, set it to a generic if(error != NULL && *error == NULL) {
g_set_error_literal(error, GPLUGIN_DOMAIN, 0, "failed to query");
@@ -374,9 +387,9 @@
gplugin_perl_loader_new(void)
- return GPLUGIN_LOADER(g_object_new(
GPLUGIN_PERL_TYPE_LOADER,
--- a/perl5/gplugin-perl5-plugin.c Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/gplugin-perl5-plugin.c Mon Oct 04 00:14:59 2021 -0500
@@ -59,7 +59,7 @@
- G_IMPLEMENT_INTERFACE(GPLUGIN_TYPE_PLUGIN, gplugin_perl_plugin_iface_init));
+ G_IMPLEMENT_INTERFACE(GPLUGIN_TYPE_PLUGIN, gplugin_perl_plugin_iface_init)) /******************************************************************************
* GPluginPlugin Implementation
--- a/perl5/tests/plugins/basic.pl Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/tests/plugins/basic.pl Mon Oct 04 00:14:59 2021 -0500
@@ -18,7 +18,8 @@
use Glib::Object::Introspection;
use Scalar::Util qw(blessed);
-Glib::Object::Introspection->setup(basename => "GPlugin", version => "1.0",
+Glib::Object::Introspection->setup(basename => "GPlugin", --- a/perl5/tests/plugins/dependent.pl Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/tests/plugins/dependent.pl Mon Oct 04 00:14:59 2021 -0500
@@ -17,7 +17,8 @@
use Glib::Object::Introspection;
-Glib::Object::Introspection->setup(basename => "GPlugin", version => "1.0",
+Glib::Object::Introspection->setup(basename => "GPlugin", --- a/perl5/tests/plugins/load-exception.pl Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/tests/plugins/load-exception.pl Mon Oct 04 00:14:59 2021 -0500
@@ -17,7 +17,8 @@
use Glib::Object::Introspection;
-Glib::Object::Introspection->setup(basename => "GPlugin", version => "1.0",
+Glib::Object::Introspection->setup(basename => "GPlugin", --- a/perl5/tests/plugins/load-failed.pl Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/tests/plugins/load-failed.pl Mon Oct 04 00:14:59 2021 -0500
@@ -17,7 +17,9 @@
use Glib::Object::Introspection;
-Glib::Object::Introspection->setup(basename => "GPlugin", version => "1.0", package=> "GPlugin");
+Glib::Object::Introspection->setup(basename => "GPlugin", return GPlugin::PluginInfo->new(
--- a/perl5/tests/plugins/unload-failed.pl Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/tests/plugins/unload-failed.pl Mon Oct 04 00:14:59 2021 -0500
@@ -17,7 +17,9 @@
use Glib::Object::Introspection;
-Glib::Object::Introspection->setup(basename => "GPlugin", version => "1.0", package => "GPlugin");
+Glib::Object::Introspection->setup(basename => "GPlugin", return GPlugin::PluginInfo->new(
--- a/perl5/tests/plugins/unload-shutdown.pl Sun Oct 03 18:13:24 2021 -0500
+++ b/perl5/tests/plugins/unload-shutdown.pl Mon Oct 04 00:14:59 2021 -0500
@@ -17,7 +17,9 @@
use Glib::Object::Introspection;
-Glib::Object::Introspection->setup(basename => "GPlugin", version => "1.0", package=> "GPlugin");
+Glib::Object::Introspection->setup(basename => "GPlugin", return GPlugin::PluginInfo->new(