Fix calling invalid CAfunction on Notification service. 61/17461/3
authorKIM JungYong <jyong2.kim@samsung.com>
Thu, 23 Feb 2017 05:58:43 +0000 (14:58 +0900)
committerUze Choi <uzchoi@samsung.com>
Mon, 27 Feb 2017 05:29:01 +0000 (05:29 +0000)
When consumer service terminated,
consumer service will unregister Network monitoring.
but, consumer service call invalid function.

In this patch,
modify calling with valid function for unregister monitoring.

Change-Id: I89c5a7f022d144c2b98a43fd956a4155d708a4c6
Signed-off-by: KIM JungYong <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/17461
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
service/notification/src/consumer/NSConsumerNetworkEventListener.c

index 4e22d7b..5dc56ca 100644 (file)
@@ -71,7 +71,7 @@ NSResult NSConsumerListenerInit()
 
 void NSConsumerListenerTermiate()
 {
-    CARegisterNetworkMonitorHandler(NULL, NULL);
+    CAUnregisterNetworkMonitorHandler(NSAdapterStateListener, NSConnectionStateListener);
     OCCancel(*getPresenceHandle(), NS_QOS, NULL, 0);
 }