platform/upstream/iotivity.git
9 years agoMake git ignore libraries and tinydtls binaries.
Ossama Othman [Mon, 22 Jun 2015 17:28:10 +0000 (10:28 -0700)]
Make git ignore libraries and tinydtls binaries.

Change-Id: I19b3a32792cbe05d48b7e944cd26ca6bcb230386
Signed-off-by: Ossama Othman <ossama.othman@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1385
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoEnable generating credId sequentially
Shilpa Sodani [Thu, 7 May 2015 04:02:03 +0000 (21:02 -0700)]
Enable generating credId sequentially

Added code to generate credId sequentially and disregard
the credId in POST credentail request.

Change-Id: I6da7343eb29817ead3a195c6b262738499d08472
Signed-off-by: Shilpa Sodani <shilpa.a.sodani@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1284
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoAddressed warnings that occurred when security was enabled.
Ossama Othman [Mon, 22 Jun 2015 16:50:30 +0000 (09:50 -0700)]
Addressed warnings that occurred when security was enabled.

Use memcpy() instead of OICStrcpyPartial() to copy remote endpoint
identity related binary data.  This addresses a pointer signedness
warning caused by a unsigned char* vs char* type mismatch.

Change-Id: I224d51439d57a0b86ae6ccb44aff5ece427459f8
Signed-off-by: Ossama Othman <ossama.othman@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1384
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoUpdated some value of CAResponseResult_t
jihwan.seo [Tue, 16 Jun 2015 12:02:00 +0000 (21:02 +0900)]
Updated some value of CAResponseResult_t

- VALID, CHANGED, CONTENT value is added.
- sample app also updated.

Change-Id: I41a59a3659bf27eb1de368ca3404e5bd101c2ed1
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1282
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hyuna Jo <hyuna0213.jo@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdded event logs to Android/Tizen for Primitive Service Assigned Jira issue IOT-555
arafat.hsn [Mon, 15 Jun 2015 12:08:08 +0000 (18:08 +0600)]
Added event logs to Android/Tizen for Primitive Service Assigned Jira issue IOT-555

Change-Id: I96dc633ac1b3117cbd2e00e14fd9797e81297160
Signed-off-by: arafat.hsn <arafat.hsn@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1276
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix possible memory leak condition in PPM for Tizen Platform.
Satya Prakash Gupta [Thu, 11 Jun 2015 13:43:08 +0000 (19:13 +0530)]
Fix possible memory leak condition in PPM for Tizen Platform.

API app_get_id allocates memory internally, which was not freed
resulting in possible memory leak.

Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Change-Id: Ibc2cc77ebe803f174ab5e7ec5cff18e54178f2a8
Reviewed-on: https://gerrit.iotivity.org/gerrit/1239
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: Harish Marappa <h.marappa@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoUpdate Broker architecture.
jyong2.kim [Mon, 22 Jun 2015 04:19:57 +0000 (13:19 +0900)]
Update Broker architecture.

Modify Architecture about Resource Presence managing by Broker directly instead of DevicePresence.
Add Class DeviceAssociation that manage device handle.
Delete unused function.

Change-Id: I1c9e39d0388ba808169e1c763daba8a8943e3189
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1372
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix NULL pointer dereferencing in ocstack
Jamal Haidar [Sat, 20 Jun 2015 06:19:07 +0000 (11:49 +0530)]
Fix NULL pointer dereferencing in ocstack

NULL check guard updated to call presenceResource.handle pointer only
when it is not NULL pointer.

Change-Id: I70f3f17b4a7b5c1f956efb7136458df0cc06f728
Signed-off-by: Jamal Haidar <jamal.haidar@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1371
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdded Valgrind generated "*.memcheck" files to the .gitignore list.
Ossama Othman [Fri, 19 Jun 2015 23:31:45 +0000 (16:31 -0700)]
Added Valgrind generated "*.memcheck" files to the .gitignore list.

Change-Id: I6483c27e7867eacd4d05205d7ab140613b23f5af
Signed-off-by: Ossama Othman <ossama.othman@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1370
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix NULL pointer deferencing in policyengine.
Satya Prakash Gupta [Thu, 18 Jun 2015 12:41:56 +0000 (18:11 +0530)]
Fix NULL pointer deferencing in policyengine.

Update ProcessAccessRequest to call IsAccessGranted only when context is
not NULL.

Change-Id: I63abb58f254a5080ba46b30203f1e43fa6b2e781
Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1359
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoModify android sample app
Jaehong Jo [Wed, 10 Jun 2015 02:35:46 +0000 (11:35 +0900)]
Modify android sample app

Modify the address to be automatically entered for testing

Change-Id: Ieaecd7e26571d1e767ef70318ec027d1c827c904
Signed-off-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1229
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[IOT-575] fixed Android Sample App in CA
jihwan.seo [Thu, 18 Jun 2015 12:37:45 +0000 (21:37 +0900)]
[IOT-575] fixed Android Sample App in CA

there are some wrong and missed codes
after IPv6 changed

Change-Id: I965dcec243fb9ae59353595ee5a89d8ea881fe34
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1358
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Naga Ashok Jampani <jn.ashok@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[IOT-570] fixed multicast issue
jihwan.seo [Wed, 17 Jun 2015 10:38:21 +0000 (19:38 +0900)]
[IOT-570] fixed multicast issue

there are some wrong codes in IPv6 changed.
CreateEndPoint(..) API need address parameter
even through Multicast

Change-Id: Ie9829c5ee56fb81446184737904a699efd941b9d
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1323
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix memory leak in Thing-Manager SampleAPP for Tizen Platform
Jamal Haidar [Tue, 16 Jun 2015 13:45:15 +0000 (19:15 +0530)]
Fix memory leak in Thing-Manager SampleAPP for Tizen Platform

In "onObserve" function locally malloc char* buf is not freed, which
creates a possible memory leak.

Change-Id: Ie8a6e6b31f580ffd4bc66c13f8f1dc3c3429a8c3
Signed-off-by: Jamal Haidar <jamal.haidar@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1283
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Harish Marappa <h.marappa@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix possible memory leak condition in PPM for Tizen Platform.
Jamal Haidar [Tue, 16 Jun 2015 11:27:39 +0000 (16:57 +0530)]
Fix possible memory leak condition in PPM for Tizen Platform.

API app_get_id allocates memory internally, which was not freed
resulting in possible memory leak.

Change-Id: I513bda2dbb407eedd9e855703188eab180974122
Signed-off-by: Jamal Haidar <jamal.haidar@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1281
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Harish Marappa <h.marappa@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoProtocol-bridge resource template and Hue example bundle
Markus Jung [Fri, 19 Jun 2015 06:09:43 +0000 (15:09 +0900)]
Protocol-bridge resource template and Hue example bundle

Added a first draft of the protocol bridge resource template and an example bundle that
illustrates the temmplate for the Philips Hue light. Namespace change to OIC::Service

Change-Id: I6e0a7e4b0db3e17d3032d53ac64bc3c4ac5afbf3
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1368
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoChange Cached Data type from map to ResourceAttributes.
jyong2.kim [Wed, 17 Jun 2015 11:05:37 +0000 (20:05 +0900)]
Change Cached Data type from map to ResourceAttributes.

change cache callback function parameter.
change getCachedData return type.
update getter member method to const member method.
change constant value to defined value.

Change-Id: Iec5af33301dfedf625fd9fcb87a989a05246c687
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1325
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoapply added namespace to ResourceContainer, change SConscript for modified library...
Minji Park [Thu, 18 Jun 2015 05:02:15 +0000 (14:02 +0900)]
apply added namespace to ResourceContainer, change SConscript for modified library name

- apply added namespace of ServerBuilder and PrimitiveResource to ResourceContainer code
- modifiy SConscript of ResourceContainer due to changed library name of ServerBuilder and PrimitiveResource

Change-Id: I52fd959be651a1bcab0300b33376ed7294433faf
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1335
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoRemove logging lines running in a tight loop that flood logs.
Mandeep Shetty [Wed, 17 Jun 2015 17:46:02 +0000 (10:46 -0700)]
Remove logging lines running in a tight loop that flood logs.

These lines flood the logs with messages that are not useful most times
in debug mode.

Change-Id: I99aadb13379242ad529f0e075df09605a4b4d692
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1331
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix compile warnings in srmutility unittest
Ravi Nanjundappa [Thu, 18 Jun 2015 06:06:43 +0000 (11:36 +0530)]
Fix compile warnings in srmutility unittest

Unit test was emitting a warning due to type mismatch of the constant.
Corrected it by explicitly using the proper type.

Change-Id: I58a5aa4bacf551aeebf011069a38f47ed3888814
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1336
Reviewed-by: Jon A. Cruz <jonc@osg.samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoRename camsgparser to cafragmentation in adapter_util directory
hyuna0213.jo [Fri, 29 May 2015 05:03:32 +0000 (14:03 +0900)]
Rename camsgparser to cafragmentation in adapter_util directory

file naming convention should be consistent throughout the entire code.
camsgparser seems to mean the control layer functionality.

Change-Id: Idb5d31fb4b480e879cb50b70588cc6ef24c6a8a6
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1134
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Naga Ashok Jampani <jn.ashok@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix memory leak in sample app for linux
Satya Prakash Gupta [Thu, 18 Jun 2015 10:12:55 +0000 (15:42 +0530)]
Fix memory leak in sample app for linux

memory free applied in leakage areas

Change-Id: I34e356ff3ff5abb0072a15c526b2b37827d5b676
Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1341
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFixed android build error
Jaehong Jo [Thu, 18 Jun 2015 06:02:30 +0000 (15:02 +0900)]
Fixed android build error

Changed to OICStrcpyPartial

Change-Id: I8fde944a0f2b85bfdbee6adc276db209574bf422
Signed-off-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1337
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Naga Ashok Jampani <jn.ashok@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoCorrect code that combined assignment with condition test.
Jon A. Cruz [Wed, 17 Jun 2015 03:11:58 +0000 (20:11 -0700)]
Correct code that combined assignment with condition test.

Combining assignment with an if() condition test is prone to
errors in maintenance, triggers compile warnings and complicates
debugging.

Also fixed missing EOL at EOF.

Change-Id: I6691fdc4de915c5c95d0fa58997398e6028beaa6
Signed-off-by: Jon A. Cruz <jonc@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1290
Reviewed-by: Younghyun Joo <yh_.joo@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoApply Primitive Resource's namespace for Broker
jyong2.kim [Wed, 17 Jun 2015 13:05:08 +0000 (22:05 +0900)]
Apply Primitive Resource's namespace for Broker

add primitive resource namespace.
update library name that is 'service_common'.
change OCConnectivityType to 'CT_IP_USE_V4'.

Change-Id: I7bec24b9e53691fcdd2a79f9436831b30697a3f5
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1329
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: kwon doil <doil.kwon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoApply changed namespace of PrimitiveResource for ResourceCache
jyong2.kim [Wed, 17 Jun 2015 11:56:45 +0000 (20:56 +0900)]
Apply changed namespace of PrimitiveResource for ResourceCache

add PrimitiveResource's namespace.
update library name that is 'service_common'.

Change-Id: I3ae06aff72d208f3966da4a42f98f7ce37f445c9
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1327
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years ago[IOT-569] fixed Transport type issue in EDR
jihwan.seo [Wed, 17 Jun 2015 10:46:56 +0000 (19:46 +0900)]
[IOT-569] fixed Transport type issue in EDR

there is previous Transport type in IPv6 changed.

Change-Id: Id91b83d673baa83bf562c68f8521f5563f931c37
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1324
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[IOT-568] fixed linux sample app in CA
jihwan.seo [Wed, 17 Jun 2015 10:26:57 +0000 (19:26 +0900)]
[IOT-568] fixed linux sample app in CA

there are some wrong and missed codes in IPv6 changed.

Change-Id: I408a5c079a8ef1228194ce51b55a26dcd6f8c380
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1322
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix segfault on GET for device and platform info.
Mandeep Shetty [Tue, 16 Jun 2015 17:11:13 +0000 (10:11 -0700)]
Fix segfault on GET for device and platform info.

The mandatory fields for device and platform are not enforced by the
stack on init. They are enforced only when the info is explicitly added.
Servers that did not register this device and platform info segfaulted
when getting discovery requests from clients.
Added a null check before dereferencing a pointer to fix the problem.

Change-Id: I8b77d149014329e60f8aa8e9c1efb761394487da
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1285
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFixed Provisioning API handling for empty and malformed payload
Randeep Singh [Tue, 16 Jun 2015 02:53:24 +0000 (11:53 +0900)]
Fixed Provisioning API handling for empty and malformed payload

please refer for details https://jira.iotivity.org/browse/IOT-564

Change-Id: I04a8ca6946b6d1c371e5235303f4733c5214674e
Signed-off-by: Randeep Singh <randeep.s@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1279
Tested-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoFix compile warning in oic_string unit test.
Jon A. Cruz [Wed, 17 Jun 2015 02:59:21 +0000 (19:59 -0700)]
Fix compile warning in oic_string unit test.

Unit test was emitting a warning due to type mismatch of the constant.
Corrected it by explicitly using the proper type.

Change-Id: Ibabdf289a46df025007b091b8a5e05f5a6ce7821
Signed-off-by: Jon A. Cruz <jonc@osg.samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1289
Reviewed-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agolibcoap: fix big endian problems
Hauke Mehrtens [Mon, 8 Jun 2015 19:57:52 +0000 (21:57 +0200)]
libcoap: fix big endian problems

When this is build for a big endian Linux system WORDS_BIGENDIAN was
not be set. This patch sets it correctly so it will not generate broken
code on big endian systems.
This was tested on MIPS BE 32 Bit.

Change-Id: I59dd07d8020c553318e2aa43894a2185fe9b9286
Signed-off-by: Hauke Mehrtens <hauke.mehrtens@lantiq.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1219
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix test code to apply base changed regarding OCConnectivityType
coderhyme [Wed, 17 Jun 2015 09:44:20 +0000 (18:44 +0900)]
Fix test code to apply base changed regarding OCConnectivityType

Change-Id: Id9d4a2b90080114787ada4f14aabaaacc3cd368c
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1321
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd destructor to PrimitiveServerResource to unregister resource automatically
coderhyme [Sat, 13 Jun 2015 04:39:54 +0000 (13:39 +0900)]
Add destructor to PrimitiveServerResource to unregister resource automatically

Change-Id: I31814a6c720154bdbd2eebeb20c9b3204af89940
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1307
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoFormat source to follow coding standard
coderhyme [Tue, 16 Jun 2015 08:24:55 +0000 (17:24 +0900)]
Format source to follow coding standard

Change-Id: I9de351d67b64580ea22a7b3084d4234464ce7c56
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1316
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd additional unit tests for ResourceAttributes
coderhyme [Wed, 17 Jun 2015 05:26:32 +0000 (14:26 +0900)]
Add additional unit tests for ResourceAttributes

Change-Id: I862f64c4cc1a5d2cc7c40f0ae30a3be1d29e2341
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1319
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd unittests for PresenceSubscriber
coderhyme [Wed, 17 Jun 2015 08:45:37 +0000 (17:45 +0900)]
Add unittests for PresenceSubscriber

Change-Id: I7102ad07b25f91600f6b4f397482575622d77ca7
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1320
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd exception descriptions to explain what error is
coderhyme [Sat, 13 Jun 2015 04:59:58 +0000 (13:59 +0900)]
Add exception descriptions to explain what error is

Move two exceptions to another header which is more appropriate place to be defined.

Change-Id: Ibbc2d0a057f97f285ebc17acf2abce6b67e22af7
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1308
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoImplement a basic version of ResponseStatement
coderhyme [Fri, 12 Jun 2015 07:58:22 +0000 (16:58 +0900)]
Implement a basic version of ResponseStatement

Change-Id: I628e51183c8a22b6aca518432640b306eb0f1c2a
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1302
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoRemove unnecessary using-declarations from PrimitiveResource
coderhyme [Fri, 12 Jun 2015 07:30:51 +0000 (16:30 +0900)]
Remove unnecessary using-declarations from PrimitiveResource

Change-Id: I204c9972ec1ba42d2e16d070ba1012f3b5b09cb1
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1301
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoChange raw pointer parameters to use shared ptr
coderhyme [Fri, 12 Jun 2015 06:06:49 +0000 (15:06 +0900)]
Change raw pointer parameters to use shared ptr

Change-Id: Ia5c156a974523c4cc369e460cf751ffb89710c83
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1297
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd namespace to common PrimitiveResource
coderhyme [Fri, 12 Jun 2015 06:57:34 +0000 (15:57 +0900)]
Add namespace to common PrimitiveResource

Change-Id: Iccb22fd14bcd2964bc2de7792d0ccb4d3b64f089
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1299
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix minor bug of isTypeOf method of ResourceAttributes
coderhyme [Wed, 17 Jun 2015 05:32:27 +0000 (14:32 +0900)]
Fix minor bug of isTypeOf method of ResourceAttributes

Change-Id: I3dea89be5e76b8b022837418e7cf181a985de413
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1293
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd unittests to server builder
coderhyme [Tue, 16 Jun 2015 08:23:14 +0000 (17:23 +0900)]
Add unittests to server builder

Change-Id: I09a933a7bb58b2ae92a372b14d2957a94223968b
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1314
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoDefine const values for RequestHandler default values
coderhyme [Tue, 16 Jun 2015 08:04:32 +0000 (17:04 +0900)]
Define const values for RequestHandler default values

Change-Id: I8c34cb6bd04592c7299af2ffaa063198599f78a6
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1312
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix build error caused by not including header path for gtest
coderhyme [Tue, 16 Jun 2015 05:50:27 +0000 (14:50 +0900)]
Fix build error caused by not including header path for gtest

Change-Id: If7c096efe89cb42138a80870840d834d29296a73
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1311
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoCompose RequestHandler unit tests
coderhyme [Sat, 13 Jun 2015 08:30:34 +0000 (17:30 +0900)]
Compose RequestHandler unit tests

Change-Id: Ibeda49a84f1d2801bbc37ca918287be22261061a
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1310
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoCompose PrimitiveServerResource unit tests
coderhyme [Sat, 13 Jun 2015 08:07:52 +0000 (17:07 +0900)]
Compose PrimitiveServerResource unit tests

Change-Id: Ied00c67d5ba1d98ab9901fbf99c968893a3e794c
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1309
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd a new PrimitiveServerResouce::LockGuard Constructor for PrimitiveServerResouce...
coderhyme [Sat, 13 Jun 2015 04:32:04 +0000 (13:32 +0900)]
Add a new PrimitiveServerResouce::LockGuard Constructor for PrimitiveServerResouce::Ptr type

Change-Id: Ic7e5d32f79beda80635b58209449e6946f730c79
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1306
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd exception handling in server builder to convert OCException into PrimitiveException
coderhyme [Sat, 13 Jun 2015 04:30:51 +0000 (13:30 +0900)]
Add exception handling in server builder to convert OCException into PrimitiveException

Change-Id: I372ef6bbbb1d7521bdae46572165df51bc080ec4
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1305
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd test file for PresenceSubscriber
coderhyme [Wed, 17 Jun 2015 05:25:44 +0000 (14:25 +0900)]
Add test file for PresenceSubscriber

Change-Id: I5f973b07232057a8aec8138653965af9ca952dd4
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1318
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoImplement draft version of ResponseStatement
coderhyme [Fri, 12 Jun 2015 06:03:03 +0000 (15:03 +0900)]
Implement draft version of ResponseStatement

Change-Id: Ie1a8ac56274a30cd4cac5f89f87d046b4d5eb452
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1292
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd namespace to ServerBuilder
coderhyme [Fri, 12 Jun 2015 06:05:12 +0000 (15:05 +0900)]
Add namespace to ServerBuilder

Change-Id: Ibb7ea2db5f76d9fe3faed28bc5f9384f3e7db584
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1295
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd Control Presence Callback
doil.kwon [Mon, 15 Jun 2015 10:57:36 +0000 (19:57 +0900)]
Add Control Presence Callback

Add Device/Resource Presence Check
Add Log Message using OC_LOG
Fix Merge Conflict File(Sconscript)
Add description about enum class in BrokerTypes.h
Delete  the meaningless blank
Add Timer Logic
(is not fixed until now,after finishing timer class,will be fixed)
Fix the issues about Patch set4's comments

Change-Id: I5eb87f4da751a54f5224c0d0b14ddedccb7d53f6
Signed-off-by: doil.kwon <doil.kwon@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1275
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoRemove unnecessary constructors of ResourceAttributes
coderhyme [Fri, 12 Jun 2015 06:06:10 +0000 (15:06 +0900)]
Remove unnecessary constructors of ResourceAttributes

Change-Id: Iede8ffe5c4aa5f12a40333e4b101cf1fe640b436
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1296
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoChange lib name in Resource Manipulation common
coderhyme [Sat, 13 Jun 2015 04:28:49 +0000 (13:28 +0900)]
Change lib name in Resource Manipulation common

Change-Id: Ic4a8d2a6900cd28c3427b43c7b936da9dee4ba6f
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1304
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoModify scon script for primitive resource to measure code coverage using gcov
coderhyme [Wed, 17 Jun 2015 02:17:31 +0000 (11:17 +0900)]
Modify scon script for primitive resource to measure code coverage using gcov

Change-Id: I4919bb36c61b33a3d8b8b04197e4aa1affbbeae4
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1317
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd unittests for PrimitiveResponse
coderhyme [Tue, 16 Jun 2015 08:24:11 +0000 (17:24 +0900)]
Add unittests for PrimitiveResponse

Change-Id: I18d49cc874057c6e47696e74bef098a07bfcc748
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1315
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoModify scon script to measure code coverage using gcov
coderhyme [Tue, 16 Jun 2015 08:22:15 +0000 (17:22 +0900)]
Modify scon script to measure code coverage using gcov

Change-Id: I0727bc5450509fd7780b7fdcb1392bc2bd57d27c
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1313
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoConvert line delimiters to unix style of scon script
coderhyme [Sat, 13 Jun 2015 03:17:45 +0000 (12:17 +0900)]
Convert line delimiters to unix style of scon script

Change-Id: I507adea856a409360e2af7b7e8d01278349294bb
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1303
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoRemove header dependency on OC header from ResourceAttributes header
coderhyme [Fri, 12 Jun 2015 07:13:28 +0000 (16:13 +0900)]
Remove header dependency on OC header from ResourceAttributes header

Change-Id: Ic43edb5da72a1f257c73686db58e525a200ad9a1
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1300
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd namespace to PresenceSubscriber
coderhyme [Fri, 12 Jun 2015 06:38:07 +0000 (15:38 +0900)]
Add namespace to PresenceSubscriber

Change-Id: Ibb774d6ec49996ef4d0e8234ee39b556566ac311
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1298
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd exception descriptions
coderhyme [Fri, 12 Jun 2015 06:04:25 +0000 (15:04 +0900)]
Add exception descriptions

Change-Id: Ib0ac31a52a4ceb58b931426ea76745e4467b74f1
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1294
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agoMerge "Merge branch 'master' into resource-manipulation" into resource-manipulation
Uze Choi [Wed, 17 Jun 2015 05:32:37 +0000 (05:32 +0000)]
Merge "Merge branch 'master' into resource-manipulation" into resource-manipulation

9 years agoAdd util methods for ResourceAttributes
coderhyme [Mon, 15 Jun 2015 11:00:24 +0000 (20:00 +0900)]
Add util methods for ResourceAttributes

Change-Id: Id8747dc53e439086c123eb7e34d53c1130cd8fcb
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1274
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUpdate Resource Cache
YounghyunJoo [Mon, 15 Jun 2015 08:59:51 +0000 (17:59 +0900)]
Update Resource Cache

- Fix Sconscript file to use service common library.
- Fix resourceCache codes for the latest primitive resource.

Change-Id: I9212afd7c6efef9cebfd1d625b997ad37c39df61
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1269
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix segfault in ocserver on invalid PUT json
Charlie Lenahan [Tue, 16 Jun 2015 22:01:27 +0000 (18:01 -0400)]
Fix segfault in ocserver on invalid PUT json

If a client does a PUT with json that has the old "oc"
instead of "oic" it will cause a crash.

Change-Id: I05764cf7fe5613486d55d3a81cc757f45204dad3
Signed-off-by: Charlie Lenahan <charlie.lenahan@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1286
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoMerge branch 'master' into resource-manipulation
hunje.yeon [Wed, 17 Jun 2015 01:27:48 +0000 (10:27 +0900)]
Merge branch 'master' into resource-manipulation

Update recent changes of 'master' into 'resource-manipulation' branch

Change-Id: I960f07005244e7abe3ec24c8d4505b7dd3edecc3
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
9 years agoIP address plumbing changes to support IPv6
Sachin Agrawal [Tue, 16 Jun 2015 19:07:57 +0000 (12:07 -0700)]
IP address plumbing changes to support IPv6

IPv6 selection logic and IPv6 modifiers are now available throughout
the stack.
Builds with all samples and tests.
Works with IPv4.
Merged with security update.
Supports JIRA IOT-476,477,488,489,493,509,548

Change-Id: I539879aeeb5aeddf2b136d81fdf1247c2af12b5f
Signed-off-by: John Light <john.j.light@intel.com>
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1081
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoReplace/examine usages of mem* and strcat/strcpy
Erich Keane [Thu, 4 Jun 2015 23:33:04 +0000 (16:33 -0700)]
Replace/examine usages of mem* and strcat/strcpy

The codebase has a large number of mis-uses of memset, memcpy,
strcat, and strcpy.  This patch replaces them with OICStrdup,
OICStrcpy, and OICStrcat where possible, and fixes a number of
issues with memcpy/memset usages throughout the code.

Change-Id: Ifa03ed611778488c28f261266eb9a8821fa4db5c
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1208
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Doug Hudson <douglas.hudson@intel.com>
9 years agoFixed double free corruption in occlientbasicops handler
Moumita Ray [Thu, 11 Jun 2015 16:22:25 +0000 (09:22 -0700)]
Fixed double free corruption in occlientbasicops handler

The scenario described in IOT-554 caused memory corruption in occlientbasicops
where OICFree is called twice in order to clean up ResourceNode List.
Removing explicit free calls in freeResourceList fixes the problem described
in IOT-554.

Change-Id: If5be1104cfb8804846f8fd684d59b018fb0401ba
Signed-off-by: Moumita Ray <moumita.ray@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1244
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdded REST query parser
Sachin Agrawal [Mon, 15 Jun 2015 18:48:01 +0000 (11:48 -0700)]
Added REST query parser

Implemented rest query parser and added unit test for the parser's API.
Also added code to handle query in Doxm resource.

Change-Id: Id3dc6c171d9faa25a44849b316eaa54171a997a6
Signed-off-by: Shilpa Sodani <shilpa.a.sodani@intel.com>
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1216
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoProvisioning Manager to send CON request
Sakthivel Samidurai [Fri, 12 Jun 2015 18:46:32 +0000 (11:46 -0700)]
Provisioning Manager to send CON request

Replace non-confirmable request to confirmable for the Provisioning
Manager.

Change-Id: I2cae1564d1c96c1cb35ced97813983467a6d96f2
Signed-off-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1260
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Shilpa Sodani <shilpa.a.sodani@intel.com>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoUpdated README files to refer to usage of scons
Ravi Nanjundappa [Fri, 12 Jun 2015 09:43:12 +0000 (15:13 +0530)]
Updated README files to refer to usage of scons

Changed README files in resource/csdk/connectivity/samples/linux/
and resource/csdk/stack/ directories to refer to usage of scons
instead of make commands.
Removed trailing whitspaces as well, as recommended from Erich
and also removed the references to sample.sh as per
https://gerrit.iotivity.org/gerrit/#/c/1253/

Change-Id: I9f61ea80c12b48f0a86ea4ff24e0758d288ddc8e
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1254
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoRemove sample.sh file
Ravi Nanjundappa [Fri, 12 Jun 2015 09:23:41 +0000 (14:53 +0530)]
Remove sample.sh file

sample.sh file in resource/csdk/connectivity/samples/linux/
directory is not used after scons adaption. We can remove this file

Change-Id: Ica2bc6188696fd44a567b053dce899431252f0e1
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1253
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix PresenceSubscriber to work correctly with move constructor
coderhyme [Fri, 12 Jun 2015 06:01:58 +0000 (15:01 +0900)]
Fix PresenceSubscriber to work correctly with move constructor

Change-Id: Id9fae6f0fe89e90d3a78827a12eac0810c3ada4b
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1250
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUpdate Resource container - server builder integration, softsensor template,
Minji Park [Mon, 15 Jun 2015 06:20:48 +0000 (15:20 +0900)]
Update Resource container - server builder integration, softsensor template,

- integrate server builder to create bundle resource
- add first version of basic resource template and resource template for soft sensor
- apply IoTivity c++ format to Resource Container codes

Change-Id: I502c9a48256d51da2227ed766851e7d1d72362a0
Signed-off-by: Minji Park <minjii.park@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1268
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd assertion util to handle OCStackResult code with exception
coderhyme [Fri, 12 Jun 2015 06:01:19 +0000 (15:01 +0900)]
Add assertion util to handle OCStackResult code with exception

Change-Id: I574da5d88abef73bf89c800bdf2a1bc10460d1e4
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1249
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUpdated resource discovery parsing logic for new 'policy' node
Sachin Agrawal [Thu, 11 Jun 2015 23:39:56 +0000 (16:39 -0700)]
Updated resource discovery parsing logic for new 'policy' node

Recently resource discovery payload was updated to add a new
policy node. This changeset updated the payload parsing logic
for secure client application.

Change-Id: I3b256a0f3f496fe058890eec92587eb5b2fab241
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1246
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFixed memory leak in OICStrdup test
Erich Keane [Fri, 12 Jun 2015 16:55:05 +0000 (09:55 -0700)]
Fixed memory leak in OICStrdup test

OICStrdup test didn't release its result memory, this fix
ensures that it is properly released.

Change-Id: Ieb271c5fbace45a730905de4dd02f2208bbf42e5
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1259
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoUpdate NDK build with common source location change
jnashok [Thu, 4 Jun 2015 08:18:03 +0000 (17:18 +0900)]
Update NDK build with common source location change

oic_malloc and oic_string are moved to resource/c_common directory
in the patch https://gerrit.iotivity.org/gerrit/#/c/1163/
Updating android make file with the changes to fix the build

Change-Id: I297b6a25ee6a7fd744174194f9e37a877ba7cd57
Signed-off-by: jnashok <jn.ashok@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1191
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Hyuna Jo <hyuna0213.jo@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdded unit tests for StackStop
Ravi Nanjundappa [Fri, 12 Jun 2015 08:59:57 +0000 (14:29 +0530)]
Added unit tests for StackStop

Unit test modified to exercise code paths
* for checking OCStop() without any OCInit()
* to check for repeated OCStop()s after one OCInit()

Change-Id: I78a817befdce335d3dba40e5aee62275784f4ef2
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1252
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix cross compile link error
Caiwen Zhang [Fri, 12 Jun 2015 01:10:45 +0000 (09:10 +0800)]
Fix cross compile link error

If call ld directly some flags (e.g. -m32) can't be recoglized.

Change-Id: I7f0c62c9f9e7530baf61ed9c658aa1cb15008009
Signed-off-by: Caiwen Zhang <caiwen.zhang@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1248
Reviewed-by: Nirav Shah <nirav.j2.shah@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoChanging ocstack to retrieve double instead of int using cJson
Omkar Hegde [Thu, 11 Jun 2015 22:09:38 +0000 (15:09 -0700)]
Changing ocstack to retrieve double instead of int using cJson

Previously, we retrieved the sequence no. from presence payload
using object->valueint. Since the sequence no. is 32-bit unsigned
int, this caused the valueint to overflow. Hence, changing it to
object->valuedouble. This should fix IOT-549.

Change-Id: Idd30408c617e2ff84faa7c7c7f2a3f028577d337
Signed-off-by: Omkar Hegde <omkar.m.hegde@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1245
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoBasic implementation of PrimitiveResource and ServerBuilder
coderhyme [Wed, 10 Jun 2015 09:52:14 +0000 (18:52 +0900)]
Basic implementation of PrimitiveResource and ServerBuilder

It include base facilities for Resource Manipulation and ServerBuilder.

Change-Id: I28b774fd06691f2ed06462e248297e64b8f3b96b
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1232
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Tested-by: Uze Choi <uzchoi@samsung.com>
9 years agofix master because cherry-picked change broke build
Charlie Lenahan [Thu, 11 Jun 2015 19:20:53 +0000 (15:20 -0400)]
fix master because cherry-picked change broke build

Change-Id: Idded4c0bedd28ce6d2064737f1ec1b7ddc630599
Signed-off-by: Charlie Lenahan <charlie.lenahan@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1243
Reviewed-by: Erich Keane <erich.keane@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoAdd EntityHandler callback parameter to C SDK.
Charlie Lenahan [Tue, 19 May 2015 20:54:32 +0000 (16:54 -0400)]
Add EntityHandler callback parameter to C SDK.

Allows C api users to have a context callback parameter
with the use of EntityHandler callbacks for OCCreateResource.

Change-Id: I1358b6dbd5c2a9a1940f6146a87aacf84c16bb3c
Signed-off-by: Charlie Lenahan <charlie.lenahan@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1042
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Gabriel Schulhof <gabriel.schulhof@intel.com>
Reviewed-by: Patrick Lankswert <patrick.lankswert@intel.com>
9 years agoMerge branch 'master' into resource-manipulation
hunje.yeon [Thu, 11 Jun 2015 14:32:00 +0000 (23:32 +0900)]
Merge branch 'master' into resource-manipulation

update latest changes of master branch to resource-manipulation branch

Change-Id: Iae8d234f55c0f2befb83c5e7b3d8b215d156e0a0
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
9 years agoAdd ResourceBroker Sconscript
jyong2.kim [Wed, 10 Jun 2015 10:01:16 +0000 (19:01 +0900)]
Add ResourceBroker Sconscript

fix build error and syntax error.
change from normal pointer to smart pointer.

Change-Id: I52ea5b2cf6b7da34fed9f9271e942f45185fae20
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1231
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd ResourceCache Sconscript
jyong2.kim [Wed, 10 Jun 2015 04:15:32 +0000 (13:15 +0900)]
Add ResourceCache Sconscript

fix build error and syntax error.
arrange the pointer.
fix ResponseStatement's error.

Change-Id: Iea690231a9c139867c80eed6dd63b3033285836a
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1230
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoResource container update
Markus Jung [Sun, 7 Jun 2015 08:09:52 +0000 (17:09 +0900)]
Resource container update

Dynamic loading of resource bundles and activation. Configuration based container initialization.
Example resource bundle and configuration file.
Separation of ContainerAPI to initialize, configure the container and resource bundles and
BundleAPI to be used by resource bundles.

Change-Id: Ib91fc12ad350f3cbd0723b83ee65c953775328ce
Signed-off-by: Markus Jung <markus.jung@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1235
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix for the Jira issue IOT-538
Jay Sharma [Fri, 5 Jun 2015 13:08:29 +0000 (18:38 +0530)]
Fix for the Jira issue IOT-538

CpluffAdapter::findPlugins and PluginManagerImpl::findPlugins methods include the
plugins which does not have the attribute of parameter "key" and when the parameter
"value" is empty string. Modified the code to handle the case where getValueByAttribute
method returns empty string value.

Change-Id: Ia2564bff28b273a3552686d16374198e223f0bb2
Signed-off-by: Jay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1206
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix Android Plugin code file
YounghyunJoo [Tue, 9 Jun 2015 07:34:07 +0000 (16:34 +0900)]
Fix Android Plugin code file

For changed base code

Change-Id: If3a40333cb09a6c3bb2d6a01d275114a7ec45b14
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1225
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFixed possible memory leak condition.
Randeep Singh [Fri, 5 Jun 2015 08:05:53 +0000 (17:05 +0900)]
Fixed possible memory leak condition.

Provisioning API returns list of unprovisioned devices. If parameter for
list is not null it can cause memory leak, changed code from just warning
from API to error and corrected test case according to it

Change-Id: I7ffe7efe116add643c1b062f2396d3486d677273
Signed-off-by: Randeep Singh <randeep.s@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1203
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoUpdate pstat property name
Sakthivel Samidurai [Mon, 8 Jun 2015 18:57:06 +0000 (11:57 -0700)]
Update pstat property name

Update the pstate commit hash property name based on the
security specification.

Change-Id: Id965150e9a1b17920e9c6339a7bc967e63f6f318
Signed-off-by: Sakthivel Samidurai <sakthivel.samidurai@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1217
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoAdded unit tests for StackStart
Ravi Nanjundappa [Tue, 9 Jun 2015 08:59:16 +0000 (14:29 +0530)]
Added unit tests for StackStart

Unit test exercise code path to check for zero length
Manufacturer Name in OCSetPlatformInfo()

Change-Id: Ic0003ba1041d14a0de1e55a09f5ff6181bc19a7f
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1226
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[ARDUINO] Modified sample to let user select response
Abhishek Sharma [Fri, 5 Jun 2015 08:57:22 +0000 (14:27 +0530)]
[ARDUINO] Modified sample to let user select response

Modified sample to let user select response to a request

Change-Id: I3ce60015ce2dff382429bb546618950b6080dabd
Signed-off-by: Abhishek Sharma <ce.abhishek@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1204
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[TIZEN] Fix broken build caused by c_common merge
Abhishek Sharma [Wed, 10 Jun 2015 14:32:23 +0000 (20:02 +0530)]
[TIZEN] Fix broken build caused by c_common merge

Tizen build was broken after merging of oic_malloc / oic_string.

Change-Id: I81ed8e5e5d5d13fd741ec66ac108f58430c8dcb9
Signed-off-by: Abhishek Sharma <ce.abhishek@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1233
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agocdsk: fix big endian problem
Hauke Mehrtens [Mon, 8 Jun 2015 20:03:19 +0000 (22:03 +0200)]
cdsk: fix big endian problem

Without this patch the client will endianes swap the port number when
sending the detailed request after it got the answer for his multicast
get. Use the same method for storing the port number in the address
array in ever part of the code and do not use memcpy and manual
bytewise coping mixed over the code. memcpy was used once and byte wise
copy was used twice so I choose the majority.
This was tested on MIPS BE 32 Bit.

Change-Id: Ib486171987004d10209d2bbf6b1d9ada75235651
Signed-off-by: Hauke Mehrtens <hauke.mehrtens@lantiq.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1220
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Doug Hudson <douglas.hudson@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoIncrease delay in presence notifications to avoid stability issues.
Mandeep Shetty [Mon, 8 Jun 2015 17:22:35 +0000 (10:22 -0700)]
Increase delay in presence notifications to avoid stability issues.

The C sample server, ocserver.cpp had a delay of 5 seconds before
sending out presence notifications. Failing to start the client would
cause missed notifications.
Increased delay to avoid false stability issues when testing.
This addresses IOT-546.

Change-Id: I2c9a7810d71886ff3abe7024c1f583bcd4ab65c5
Signed-off-by: Mandeep Shetty <mandeep.shetty@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1215
Reviewed-by: Mark Tung <mark.y.tung@intel.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Doug Hudson <douglas.hudson@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>