X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=resource%2Fcsdk%2Fstack%2Fsrc%2Focstack.c;h=f588187c932340653479bd195857a077c9dcf6b4;hb=03c42f9b68da8054f76ee2e2a1a9318dcffb5fde;hp=cee39e4d696707c8f2cf6d10adc34035d82b370e;hpb=825d77740ba8e697deda3268eecfb1192d16c0e6;p=platform%2Fupstream%2Fiotivity.git diff --git a/resource/csdk/stack/src/ocstack.c b/resource/csdk/stack/src/ocstack.c index cee39e4..f588187 100644 --- a/resource/csdk/stack/src/ocstack.c +++ b/resource/csdk/stack/src/ocstack.c @@ -1789,12 +1789,9 @@ void HandleCAResponses(const CAEndpoint_t* endPoint, const CAResponseInfo_t* res * proper destination and remove "RM" coap header option before passing request / response to * RI as this option will make no sense to either RI or application. */ - if (responseInfo->info.options) - { - RMUpdateInfo((CAHeaderOption_t **) &(responseInfo->info.options), + RMUpdateInfo((CAHeaderOption_t **) &(responseInfo->info.options), (uint8_t *) &(responseInfo->info.numOptions), (CAEndpoint_t *) endPoint); - } #endif OCHandleResponse(endPoint, responseInfo); @@ -2240,12 +2237,6 @@ void OCHandleRequests(const CAEndpoint_t* endPoint, const CARequestInfo_t* reque { OIC_LOG_V(ERROR, TAG, "HandleStackRequests failed. error: %d", requestResult); - // Delete observer node if it is OBSERVE failure from app - if (serverRequest.observationOption == OC_OBSERVE_REGISTER) - { - DeleteObserverUsingToken(requestInfo->info.token, requestInfo->info.tokenLength); - } - CAResponseResult_t stackResponse = OCToCAStackResult(requestResult, serverRequest.method); @@ -2306,12 +2297,9 @@ void HandleCARequests(const CAEndpoint_t* endPoint, const CARequestInfo_t* reque * Put source in sender endpoint so that the next packet from application can be routed to * proper destination and remove RM header option. */ - if (requestInfo->info.options) - { - RMUpdateInfo((CAHeaderOption_t **) &(requestInfo->info.options), + RMUpdateInfo((CAHeaderOption_t **) &(requestInfo->info.options), (uint8_t *) &(requestInfo->info.numOptions), (CAEndpoint_t *) endPoint); - } #ifdef ROUTING_GATEWAY if (isEmptyMsg)