Introspection with GUPnP


[I'm resending this as I originally sent it before I joined the
mailing list, and I've not seen it appear on the list archives. Sorry
if it dupes]

I'm hoping someone might be able to help me with the following.

I've been using the Glib::Object::Introspection perl module to call
into the GUPnP package, and it's been working really really well.
Well done guys.

However, when I call some of the routines on,
specifically ones that return a GError and other return values, I'm
getting assertion errors.

The following code snippet demonstrates the issue. I'm using
Glib::Object::Introspection 0.027, gboject-introspection 1.41.4 and
gupnp 0.20.12.

use Glib::Object::Introspection;

my $next_state = 1;

    basename => 'GUPnP',
    version => '1.0',
    package => 'GUPnP',

    basename => 'GSSDP',
    version => '1.0',
    package => 'GSSDP',

my $main_loop = Glib::MainLoop->new(undef, 0);

my $context = GUPnP::Context->new(undef, undef, 0);

my $control_point = GUPnP::ControlPoint->new($context,


$control_point->signal_connect('device-proxy-available' => \&discovered);

GSSDP::ResourceBrowser::set_active($control_point, 1);


my @services;

sub discovered
    my ($control_point, $device_proxy) = @_;

    print "Discovered: ". $device_proxy->get_friendly_name . "\n";

    my $service_proxy =

    my $service_action_proxy = $service_proxy->begin_action_list (


        [Glib::Object::Introspection::GValueWrapper->new ('Glib::Boolean',
                                                          $next_state ? 1 : 0)],



    push @services,  $service_proxy;

    $next_state = !$next_state;

sub action_callback
    my ($service_proxy, $service_proxy_action) = @_;

    print "Action complete\n";

    # In newer GUPnP I think this can be undef
    my $error =  Glib::File::Error->new ('io', '');

    my ($success, $out_values) = $service_proxy->end_action_list
         [ ], [ ]

Run it with a gupnp-network-light running, and the output I get is:

Discovered: GUPnP Network Light
Action complete
ERROR:gperl-i11n-marshal-arg.c:116:sv_to_arg: assertion failed:
Aborted (core dumped)

I have tried commenting out the assertions, and it runs further, but
then I'm getting a double-free error in gperl-i11n-marshal-interface.c
around line 116 where g_boxed_free is called.

I'm guessing there's something not expected going on.

Can anyway suggest how we can get this call working?

Thanks in advance,

Nick Glencross

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]