projects
/
contrib
/
iotivity.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix to prevent of crash on the unit test.
[contrib/iotivity.git]
/
service
/
notification
/
src
/
consumer
/
NSConsumerScheduler.c
diff --git
a/service/notification/src/consumer/NSConsumerScheduler.c
b/service/notification/src/consumer/NSConsumerScheduler.c
index
b5fd6b9
..
c299b31
100644
(file)
--- a/
service/notification/src/consumer/NSConsumerScheduler.c
+++ b/
service/notification/src/consumer/NSConsumerScheduler.c
@@
-170,7
+170,7
@@
void * NSConsumerMsgHandleThreadFunc(void * threadHandle)
break;
}
break;
}
- NSConsumerQueue * queue = *(NSGetMsgHandleQueue());
;
+ NSConsumerQueue * queue = *(NSGetMsgHandleQueue());
if (!queue)
{
usleep(2000);
if (!queue)
{
usleep(2000);
@@
-192,6
+192,7
@@
void * NSConsumerMsgHandleThreadFunc(void * threadHandle)
NSThreadLock(queueHandleThread);
NS_LOG(DEBUG, "msg handler working");
NSThreadLock(queueHandleThread);
NS_LOG(DEBUG, "msg handler working");
+ queue = *(NSGetMsgHandleQueue());
obj = NSPopQueue(queue);
if (obj)
obj = NSPopQueue(queue);
if (obj)
@@
-271,6
+272,7
@@
void NSProviderDeletedPostClean(
void NSConsumerTaskProcessing(NSTask * task)
{
void NSConsumerTaskProcessing(NSTask * task)
{
+ NS_VERIFY_NOT_NULL_V(task);
switch (task->taskType)
{
case TASK_EVENT_CONNECTED:
switch (task->taskType)
{
case TASK_EVENT_CONNECTED: