The variant which is recieved as parameter should not be unref
because the intermediate gdbus codegen caller function unrefs this variant.
If we unref this variant then crash occurs in _tethering_skeleton_handle_method_call()
which is an intermediate function made using gdbus-codegen command.
=====================
(gdb) bt
>0 g_variant_type_info_check (info=info@entry=0x4,
container_class=container_class@entry=0 '\000') at gvarianttypeinfo.c:162
>1 0x76149790 in g_variant_type_info_unref (info=0x4)
at gvarianttypeinfo.c:829
>2 0x76140c68 in g_variant_unref (value=0x74601390) at gvariant-core.c:852
>3 0x76460f18 in g_value_unset (value=0x54e3a8) at gvalue.c:275
>4 0x00502bca in _tethering_skeleton_handle_method_call ()
>5 0x7655f350 in g_dbus_interface_method_dispatch_helper ()
from /lib/libgio-2.0.so.0
>6 0x765424e4 in call_in_idle_cb () from /lib/libgio-2.0.so.0
>7 0x760ffb9c in g_main_dispatch (context=0x536fb0) at gmain.c:3234
>8 g_main_context_dispatch (context=context@entry=0x536fb0) at gmain.c:3887
>9 0x760fff58 in g_main_context_iterate (context=0x536fb0,
block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>)
at gmain.c:3960
>10 0x76100318 in g_main_loop_run (loop=0x537088) at gmain.c:4156
>11 0x004e7146 in mobileap_main ()
>12 0x75ee9608 in __libc_start_main () from /lib/libc.so.6
>13 0x004e5bc0 in _start ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Change-Id: Ie109e7b0e194a0e531060ae3ba43175eb6784de4
Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
Name: mobileap-agent
Summary: Mobile AP daemon for setting tethering environments
-Version: 1.0.142
+Version: 1.0.143
Release: 1
Group: System/Network
License: Apache-2.0
}
g_variant_iter_free(iter);
- g_variant_unref(values);
DBG("-");
return MOBILE_AP_ERROR_NONE;