Dear All,<br><br>I am trying to send array of integers using GPtrArray. Bindings which I have is ,<br><br> <method name="GetAllDownloads"><br> <annotation name="org.freedesktop.DBus.GLib.CSymbol" value="downloadDaemonGetAllDownloads"/><br>
<arg type="a(u)" name="allDownloads" direction="out"/><br> </method><br><br><br>On the client side, I am calling this method as, (org_nayan_dlmgr is the object path)<br><br>
GPtrArray* gptr_all_dls = NULL;<br> org_nayan_dlmgr_get_all_downloads(remoteObject, &gptr_all_dls, &error);<br><br><br>Corresponding server side code is, <br><br>gboolean<br>downloadDaemonGetAllDownloads(DownloadDaemon* DaemonObject,<br>
GPtrArray** gptrAllDls,<br> GError** error)<br>{<br> GPtrArray* gptr_all_dls = g_ptr_array_sized_new(1);<br> gptr_all_dls->len = numDls;<br><br> g_ptr_array_add(gptr_all_dls,(gpointer)(1234567));<br>
<br> *gptrAllDls = gptr_all_dls;<br><br> return TRUE;<br>}<br><br>When I call GetAllDownloads method over DBus, it is crashing with following backtrace,<br><br>Program received signal SIGSEGV, Segmentation fault.<br>
[Switching to Thread 0xb6d95740 (LWP 7638)]<br>0xb79c6880 in g_type_check_value () from /usr/lib/libgobject-2.0.so.0<br>(gdb) bt<br>#0 0xb79c6880 in g_type_check_value () from /usr/lib/libgobject-2.0.so.0<br>#1 0xb79cce78 in g_value_copy () from /usr/lib/libgobject-2.0.so.0<br>
#2 0xb7809849 in ?? () from /usr/lib/libdbus-glib-1.so.2<br>#3 0xb7806f79 in dbus_g_type_struct_get_member () from /usr/lib/libdbus-glib-1.so.2<br>#4 0xb7804b7e in ?? () from /usr/lib/libdbus-glib-1.so.2<br>#5 0xb7804876 in ?? () from /usr/lib/libdbus-glib-1.so.2<br>
#6 0xb7809192 in ?? () from /usr/lib/libdbus-glib-1.so.2<br>#7 0xb78071ad in dbus_g_type_collection_value_iterate () from /usr/lib/libdbus-glib-1.so.2<br>#8 0xb7805c86 in ?? () from /usr/lib/libdbus-glib-1.so.2<br>#9 0xb78049c3 in ?? () from /usr/lib/libdbus-glib-1.so.2<br>
#10 0xb77fe944 in ?? () from /usr/lib/libdbus-glib-1.so.2<br>#11 0xb77d971b in ?? () from /usr/lib/libdbus-1.so.3<br>#12 0xb77cbaa6 in dbus_connection_dispatch () from /usr/lib/libdbus-1.so.3<br>#13 0xb77fb4cd in ?? () from /usr/lib/libdbus-glib-1.so.2<br>
#14 0xb791ecf6 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0<br>#15 0xb79220b3 in ?? () from /usr/lib/libglib-2.0.so.0<br>#16 0xb7922497 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0<br>#17 0x0804a7ea in main () at DownloadDaemon.cpp:303<br>
<br>Am I missing anything? Please help me. dbus-binding-tool version is 0.74.<br><br>Regards,<br>Nayan<br>