From: ChaJiWon Date: Thu, 2 Mar 2017 12:06:00 +0000 (+0900) Subject: IOT-1877 : start presence issue X-Git-Tag: accepted/tizen/ivi/20170314.224217 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Ftags%2Faccepted%2Ftizen%2Fivi%2F20170314.224217;p=platform%2Fupstream%2Fiotivity.git IOT-1877 : start presence issue When called OCStartPresence() second, OCStartPresence() returns error. Fixed presenceState variable to OC_PRESENCE_UNINITIALIZED. Change-Id: I089c826f4105eb3aaf835a8feda4c10b848ebd5d Signed-off-by: ChaJiWon Reviewed-on: https://gerrit.iotivity.org/gerrit/17623 Tested-by: jenkins-iotivity Reviewed-by: Phil Coval Reviewed-by: Jaehong Jo Reviewed-by: jihwan seo Reviewed-by: Way Vadhanasin Reviewed-by: Dan Mihai (cherry picked from commit 2f11e9592a7374ce28082a523b0c367a6d31baee) Reviewed-on: https://gerrit.iotivity.org/gerrit/17775 --- diff --git a/resource/csdk/stack/src/ocstack.c b/resource/csdk/stack/src/ocstack.c index 66ac3bf..277cd6e 100644 --- a/resource/csdk/stack/src/ocstack.c +++ b/resource/csdk/stack/src/ocstack.c @@ -2278,6 +2278,7 @@ OCStackResult OCStop() // Ensure that the TTL associated with ANY and ALL presence notifications originating from // here send with the code "OC_STACK_PRESENCE_STOPPED" result. presenceResource.presenceTTL = 0; + presenceState = OC_PRESENCE_UNINITIALIZED; #endif // WITH_PRESENCE #ifdef ROUTING_GATEWAY