IOT-970: Handle get requests on oic/p and oic/d resources
authorhekra <hekra@cisco.com>
Tue, 8 Mar 2016 14:26:03 +0000 (06:26 -0800)
committerHabib Virji <habib.virji@samsung.com>
Tue, 19 Apr 2016 18:43:17 +0000 (18:43 +0000)
Change-Id: I6a96e188f7dcb839467c4285c3b4a57871669b78
Signed-off-by: Hugues Ekra <hekra@cisco.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/5553
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Habib Virji <habib.virji@samsung.com>
(cherry picked from commit a51b71c150d30614439dbbe1c3ec0ae01bdefaeb)
Reviewed-on: https://gerrit.iotivity.org/gerrit/7843

resource/csdk/stack/src/ocstack.c

index ea37b41..c0219d0 100644 (file)
@@ -1199,6 +1199,14 @@ void OCHandleResponse(const CAEndpoint_t* endPoint, const CAResponseInfo_t* resp
                     {
                         type = PAYLOAD_TYPE_RD;
                     }
+                    else if (strcmp(OC_RSRVD_PLATFORM_URI, cbNode->requestUri) == 0)
+                    {
+                        type = PAYLOAD_TYPE_PLATFORM;
+                    }
+                    else if (strcmp(OC_RSRVD_DEVICE_URI, cbNode->requestUri) == 0)
+                    {
+                        type = PAYLOAD_TYPE_DEVICE;
+                    }
                     if (type == PAYLOAD_TYPE_INVALID)
                     {
                         OIC_LOG_V(INFO, TAG, "Assuming PAYLOAD_TYPE_REPRESENTATION: %d %s",