platform/upstream/iotivity.git
9 years agoModify server resource to make the class mockable
coderhyme [Tue, 30 Jun 2015 02:38:04 +0000 (11:38 +0900)]
Modify server resource to make the class mockable

Change-Id: Ie55f6db28183f99aab19df9c3af8b7cbea7c9a81
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1452
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoMake a member variable of ResourceAttributes::Value private
coderhyme [Tue, 30 Jun 2015 03:26:26 +0000 (12:26 +0900)]
Make a member variable of ResourceAttributes::Value private

Change-Id: Ibf0d522d1b33a48e119b4e5893fafa21c45826a3
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1453
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd Resource Cache feature that updates cache data periodically for the non-observabl...
YounghyunJoo [Tue, 30 Jun 2015 01:40:16 +0000 (10:40 +0900)]
Add Resource Cache feature that updates cache data periodically for the non-observable resource

Add Primitive Timer instance which checks the frequency and alarms
Add onTimer function to update cache data when Primitive timer alarms.

Change-Id: Ic5c9c0076058344829075e84084c75adb295eaad
Signed-off-by: YounghyunJoo <yh_.joo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1449
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoUpdate Caching cancel logic.
jyong2.kim [Thu, 25 Jun 2015 04:13:53 +0000 (13:13 +0900)]
Update Caching cancel logic.

Modify unused parameter in cancelResourceCache().
Change return type of cancelResourceCache() to CacheID
Fix Sconscript for Resource Manipulation.

Change-Id: I3723619599d40a081c58133d12a75d487ddcc8cc
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1421
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: Younghyun Joo <yh_.joo@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoRestruct resource-manipulation folders
hunje.yeon [Wed, 24 Jun 2015 12:10:19 +0000 (21:10 +0900)]
Restruct resource-manipulation folders

change 'basis' to 'resource-manipulation'
add sub-folder 'modules' for resource common funcions

Change-Id: Iec5b700d2f68cb63807da4ee2e050cbb8c8dbcdb
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1417
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
9 years agoAdd BrokerID for start and cancel Broker.
jyong2.kim [Tue, 23 Jun 2015 10:00:15 +0000 (19:00 +0900)]
Add BrokerID for start and cancel Broker.

Implementation generate BrokerID.
Implementation cancelHostResource method.
Add resource and device delete logic.
Delete unused defined value.

Change-Id: I83ac5e2af16493ff9e81c757bc523ad934b281c0
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1400
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
Reviewed-by: kwon doil <doil.kwon@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd pthread link to service common test
coderhyme [Wed, 24 Jun 2015 00:54:07 +0000 (09:54 +0900)]
Add pthread link to service common test

Change-Id: I5336e3d7a51f4ea45e784e532db366c8473654d0
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1409
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd unit test for discoverResource
coderhyme [Tue, 23 Jun 2015 08:14:06 +0000 (17:14 +0900)]
Add unit test for discoverResource

Change-Id: I69a11e7f130d681bce41e4ff32cb1f0a67994fb5
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1397
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoMerge branch 'master' into resource-manipulation
hunje.yeon [Wed, 24 Jun 2015 07:34:16 +0000 (16:34 +0900)]
Merge branch 'master' into resource-manipulation

Update the last changes of 'master' into 'resource-manipulation' branch

Change-Id: I1ddfc5d14ea01a46e52f1e6d5efe73732225d67d
Signed-off-by: hunje.yeon <hunje.yeon@samsung.com>
9 years agoAdded unit tests for StackResource
Ravi Nanjundappa [Tue, 23 Jun 2015 04:52:05 +0000 (10:22 +0530)]
Added unit tests for StackResource

Unit test exercise code paths to check OCCreateResource() for
OC_LIENT mode and also to check if resource type name is invalid
i.e., null terminated or not.
This also includes the bug fix related to checking if resource type
name is invalid i.e., null terminated or not.

Change-Id: I7f8767a4e8b9586de9cb0926dd8a4afcd03b792c
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1391
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Joseph Morrow <joseph.l.morrow@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoAdded missing DTLS #ifdef guard.
Sachin Agrawal [Mon, 22 Jun 2015 23:38:58 +0000 (16:38 -0700)]
Added missing DTLS #ifdef guard.

One of the functions only used for DTLS was missing #ifdef guards
resulting in compile warnings.

Change-Id: Ieb0082e1dba2547e8d73d0526cf0aab3bf3af589
Signed-off-by: Jon A. Cruz <jonc@osg.samsung.com>
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1333
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
9 years agoremoved duplicated code in Sample app
jihwan.seo [Tue, 23 Jun 2015 08:06:24 +0000 (17:06 +0900)]
removed duplicated code in Sample app

- Target Platform : Android, Linux

Change-Id: I7035a138cb9b83a6e653c213aaa4fc349b57545d
Signed-off-by: jihwan.seo <jihwan.seo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1395
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoRemove unused scons file in examples/OICMiddle/ for x86 linux build
Ravi Nanjundappa [Tue, 23 Jun 2015 09:02:49 +0000 (14:32 +0530)]
Remove unused scons file in examples/OICMiddle/ for x86 linux build

Actual file used is examples/OICMiddle/SConscript, So removed the unused
scons file examples/OICMiddle/SConstruct from git.

Change-Id: I9c0d3c37d0f228ed3125763f05efa7b447e4e41b
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1399
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoremove unnecessary code in messagehandler
hyuna0213.jo [Tue, 23 Jun 2015 10:55:55 +0000 (19:55 +0900)]
remove unnecessary code in messagehandler

- remove the duplicated log message for the debugging
- add the null check logic for token

Change-Id: Icfd74fcc350b6e1c9038acdac290cfcaf9d344e7
Signed-off-by: hyuna0213.jo <hyuna0213.jo@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1402
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoRemove unused make file in resource/csdk/connectivity/ for x86 linux build
Ravi Nanjundappa [Tue, 23 Jun 2015 11:15:03 +0000 (16:45 +0530)]
Remove unused make file in resource/csdk/connectivity/ for x86 linux build

Now scons are used in place of makefiles. So need to remove this left out
common.mk file from git.

Change-Id: Ice0abdc0a02ff78a9fddb0e407613d242acdffbe
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1403
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoRealigned usage of IP Adapter modules' APIs on Arduino.
Joseph Morrow [Tue, 23 Jun 2015 00:05:12 +0000 (20:05 -0400)]
Realigned usage of IP Adapter modules' APIs on Arduino.

This fixes an issue where an Arduino using an Ethernet shield did not
respond to incoming requests nor notified the application of incoming
requests.

Change-Id: I035120e7bbe4a5950d2ed36a357f06c85c1ef8db
Signed-off-by: Joseph Morrow <joseph.l.morrow@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1388
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: John Light <john.j.light@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years ago[CA] Assigned unicast port number 0 instead of fixed number
koushik.girijala [Thu, 18 Jun 2015 08:22:37 +0000 (13:52 +0530)]
[CA] Assigned unicast port number 0 instead of fixed number

Fix for jira issue IOT 379

Change-Id: Iaefe63189473fb106c5a43eb8648fc903ed3954e
Signed-off-by: koushik.girijala <g.koushik@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1338
Reviewed-by: Abhishek Sharma <ce.abhishek@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: John Light <john.j.light@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix bugs of invokeOC that causes compile errors
coderhyme [Tue, 23 Jun 2015 08:15:30 +0000 (17:15 +0900)]
Fix bugs of invokeOC that causes compile errors

Change-Id: I45ff094e58429795633666b27e23f66325ed0bfd
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1398
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd logs to where exceptions are swallowed
coderhyme [Tue, 23 Jun 2015 08:13:39 +0000 (17:13 +0900)]
Add logs to where exceptions are swallowed

Change-Id: Iacd2b4fcab6f2bf453c32264b853ad410e221900
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1396
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix a bug of discoverResource that doesn't invoke the callback even when a resource...
coderhyme [Tue, 23 Jun 2015 03:57:30 +0000 (12:57 +0900)]
Fix a bug of discoverResource that doesn't invoke the callback even when a resource is discovered.

And also change the name of callback of discoverResource

Change-Id: I36cfe430f611467b350f83d61ad9484bf422cc89
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1390
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix Bug about request hostResource logic.
jyong2.kim [Mon, 22 Jun 2015 12:52:45 +0000 (21:52 +0900)]
Fix Bug about request hostResource logic.

Change-Id: Ic004a4c09767663616215509f8b505c510ebea84
Signed-off-by: jyong2.kim <jyong2.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1383
Reviewed-by: Hun-je Yeon <hunje.yeon@samsung.com>
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 PrimitiveResource unit tests
coderhyme [Mon, 22 Jun 2015 07:31:05 +0000 (16:31 +0900)]
Add PrimitiveResource unit tests

Change-Id: If0e88c5572606a963fbc0dc52e1bad1e9e770a1d
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1378
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoChange the way calling oc to use helper methods
coderhyme [Mon, 22 Jun 2015 07:30:36 +0000 (16:30 +0900)]
Change the way calling oc to use helper methods

Change-Id: Ia8440d9f66c654c39acdf7bd66d9f80c2f36c029
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1377
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoAdd helper methods to invoke OC methods safely
coderhyme [Mon, 22 Jun 2015 07:29:01 +0000 (16:29 +0900)]
Add helper methods to invoke OC methods safely

Change-Id: I94b4310f39530587003c5c153cf6feb870f924d2
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1376
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoSeparate PrimitiveResource implementation
coderhyme [Thu, 18 Jun 2015 06:48:59 +0000 (15:48 +0900)]
Separate PrimitiveResource implementation

Change-Id: I3f209fa80a38156a0b8b668406ced390d375febe
Signed-off-by: coderhyme <jhyo.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1375
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix memory leak in Notification Manager
Satya Prakash Gupta [Thu, 18 Jun 2015 06:15:07 +0000 (11:45 +0530)]
Fix memory leak in Notification Manager

Fix memory leak in requestIsAlive when resource is not found.

Change-Id: Ia54883ac2d4f207402c4ac99a0e5304e96a39257
Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1354
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Harish Marappa <h.marappa@samsung.com>
Reviewed-by: JungYong KIM <jyong2.kim@samsung.com>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
9 years agoFix compile warnings in resource src
Ravi Nanjundappa [Wed, 17 Jun 2015 05:38:26 +0000 (11:08 +0530)]
Fix compile warnings in resource src

This patch fixes compiler warnings related to implicit declaration
of function 'strncasecmp' in resource security module

Change-Id: I4a785dde406fcaffe1acbb2b4f2c76524143c2d0
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1291
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Sachin Agrawal <sachin.agrawal@intel.com>
9 years agoFix install external libraries comment on openssl in 'Readme.scons.txt'
Jiwon Kim [Fri, 22 May 2015 11:16:48 +0000 (20:16 +0900)]
Fix install external libraries comment on openssl in 'Readme.scons.txt'
file
Add comment libssl-dev

Change-Id: I160837cf3316eaecf6e872337ec4bc79a82ac9b8
Signed-off-by: Jiwon Kim <kjo6152@naver.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1095
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Caiwen Zhang <caiwen.zhang@intel.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoRemove unused includes.
Sanjeev BA [Thu, 11 Jun 2015 06:16:48 +0000 (15:16 +0900)]
Remove unused includes.

Change-Id: Ifb5ec2dbe549d03add076d8a10844b3409484534
Signed-off-by: Sanjeev BA <as2902.b@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1238
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoClose fd after use in RestInput
Satya Prakash Gupta [Thu, 18 Jun 2015 08:48:40 +0000 (14:18 +0530)]
Close fd after use in RestInput

A socket descriptor being created in loop and not closed after use.

Change-Id: Iadf195c4bb4591bcfd124e89a08964660bc64103
Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1339
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoUpdate example applications fridgeclient & fridgeserver.
Satya Prakash Gupta [Thu, 18 Jun 2015 11:41:37 +0000 (17:11 +0530)]
Update example applications fridgeclient & fridgeserver.

Update example application to pass OCRepresentation object by reference
instead of by value.

Change-Id: I8c38f656223181e8d4a95bee328fa4c622be92fb
Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1349
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
9 years agoFix NULL pointer deferencing in sample program.
Satya Prakash Gupta [Thu, 18 Jun 2015 11:13:33 +0000 (16:43 +0530)]
Fix NULL pointer deferencing in sample program.

Fix NULL pointer deferencing in send_response.

Change-Id: Ie38dd5d4d0c95fe4a8ccc26a23612584816ef442
Signed-off-by: Satya Prakash Gupta <sp.gupta@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/1342
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Erich Keane <erich.keane@intel.com>
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>