[Multithread support] Maintain ref_count for Dbus signal registration/deregistration
Maintain ref_count for Dbus signal registration/deregistration.
Register for DBus signals only once for a process, irrespective of multiple threads.
Deregiter Dbus signals when ref_count becomes zero.
This patch also handles the case when duplicated signals are being sent to main thread because of multiple threads signal registrations.
Change-Id: I33b1b53f69538e39fdef183fc7f06122e16c324f
Signed-off-by: Shagun Garg <shagun1.garg@samsung.com>