From: Joseph Morrow Date: Tue, 14 Oct 2014 16:04:31 +0000 (-0400) Subject: Made small change to sample app to ensure that all clients are notified X-Git-Tag: 1.2.0+RC1~2160 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7f8f2d5a42bf739b22d85722936d7ee175f2b9cd;p=platform%2Fupstream%2Fiotivity.git Made small change to sample app to ensure that all clients are notified when a server's resource is deleted. Change-Id: I7eae7c365d9b570ac377d18e50c72e0477862d08 --- diff --git a/csdk/stack/src/ocstack.c b/csdk/stack/src/ocstack.c index 700f68e..d1d9d84 100644 --- a/csdk/stack/src/ocstack.c +++ b/csdk/stack/src/ocstack.c @@ -292,6 +292,9 @@ OCStackResult OCStop() return OC_STACK_ERROR; } + // Free memory dynamically allocated for resources + deleteAllResources(); + // Make call to OCCoAP layer if (OCStopCoAP() == OC_STACK_OK) { @@ -305,9 +308,6 @@ OCStackResult OCStop() result = OC_STACK_ERROR; } - // Free memory dynamically allocated for resources - deleteAllResources(); - if (result != OC_STACK_OK) { OC_LOG(ERROR, TAG, PCF("Stack stop error")); }