aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathan Heldt-Sheller <nathan.heldt-sheller@intel.com>2018-06-16 19:27:37 -0700
committerAleksey Volkov <a.volkov@samsung.com>2018-06-18 11:57:30 +0000
commitea7545effc581ab3cefc3d11b57618780d472936 (patch)
tree507c919dfa602d6478ea2347d1b431f0beef77c0
parent0bba2f80fe940271fe32e4c34dd4f54deb0f2dc6 (diff)
[IOT-3090] disable /sp Resource1.4.0-RC2
/sp Resource must be temporarily disabled until CTT is updated to recognize it (~Bangkok point release) else it causes CTT failures. Change-Id: Id52c8acaf5a76e727bedf28288c08472255a988a Signed-off-by: Nathan Heldt-Sheller <nathan.heldt-sheller@intel.com>
-rw-r--r--resource/csdk/security/src/spresource.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/resource/csdk/security/src/spresource.c b/resource/csdk/security/src/spresource.c
index 5db5df6..a019f62 100644
--- a/resource/csdk/security/src/spresource.c
+++ b/resource/csdk/security/src/spresource.c
@@ -939,9 +939,13 @@ OCEntityHandlerResult SpEntityHandler(OCEntityHandlerFlag flag,
return ehRet;
}
+#define SP_RESOURCE_DISABLE
OCStackResult CreateSpResource()
{
- OCStackResult ret = OCCreateResource(&gSpHandle,
+ OCStackResult ret = OC_STACK_OK;
+
+#ifndef SP_RESOURCE_DISABLE
+ ret = OCCreateResource(&gSpHandle,
OIC_RSRC_TYPE_SEC_SP,
OC_RSRVD_INTERFACE_DEFAULT,
OIC_RSRC_SP_URI,
@@ -954,6 +958,10 @@ OCStackResult CreateSpResource()
OIC_LOG(FATAL, TAG, "Unable to instantiate sp resource");
DeInitSpResource();
}
+#else
+ OIC_LOG_V(WARNING, TAG, "/sp Resource disabled in this build; not creating Resource.");
+#endif // SP_RESOURCE_DISABLE
+
return ret;
}