projects
/
platform
/
upstream
/
iotivity.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4a80d83
)
Fix Unicast Presence Error
author
omkar
<omkar.m.hegde@intel.com>
Mon, 8 Dec 2014 22:32:28 +0000
(14:32 -0800)
committer
omkar
<omkar.m.hegde@intel.com>
Mon, 8 Dec 2014 22:32:58 +0000
(14:32 -0800)
Fix for IOT-95. Previously we had missed a "+1" when mallocing a char *
Change-Id: I96021ddce22c2fa7e3afa8f8d10e6da10b47ebbc
Signed-off-by: omkar <omkar.m.hegde@intel.com>
resource/csdk/stack/src/ocstack.c
patch
|
blob
|
history
diff --git
a/resource/csdk/stack/src/ocstack.c
b/resource/csdk/stack/src/ocstack.c
index 14da26ab2680425205b82976eabe16fcc68056e6..e6080c9fcaddd8dccd5311e68ddadd07ada2aa97 100644
(file)
--- a/
resource/csdk/stack/src/ocstack.c
+++ b/
resource/csdk/stack/src/ocstack.c
@@
-2350,7
+2350,7
@@
OCStackResult getResourceType(const char * uri, unsigned char** resourceType, ch
return OC_STACK_INVALID_PARAM;
}
char * leftToken = NULL;
- char * tempURI = (char *) OCMalloc(strlen(uri));
+ char * tempURI = (char *) OCMalloc(strlen(uri)
+ 1
);
if(!tempURI)
{
goto exit;