libseed-list g_async_queue



I'd like to use a GAsyncQueue to communicate between threads, but:

> a = new GLib.AsyncQueue

** (seed:2468): CRITICAL **: Struct/union of type: AsyncQueue has size 0 in introspection data. Please check GIR
Segmentation fault

Trying the other way:

> a = GLib.async_queue_new()
[object seed_struct]
> GLib.async_queue_push(a,"hejsan")
> GLib.async_queue_length(a)
1
> GLib.async_queue_push(a,"hejsan")
> x=GLib.async_queue_pop(a)
> typeof x
undefined
> GLib.async_queue_length(a)
0
>

How can I get it to work?

It's a bit frustrating that the GLib/GObject bridge is only working for some stuff, and other times it requires a bit of guessing to figure out how to use them (like functions returning things to a pointer supplied as an arg, etc..)

/Jonatan



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