Make OCProcessEvent method. 89/203789/1
authorkush.agrawal <kush.agrawal@samsung.com>
Mon, 15 Apr 2019 13:24:54 +0000 (22:24 +0900)
committerDoHyun Pyun <dh79.pyun@samsung.com>
Thu, 18 Apr 2019 00:52:37 +0000 (09:52 +0900)
commitbf35fda40df5fb3d1736281cc0556fadb67ec385
treefdef70d1d585e5440fb68ef1095024e537dd0922
parent9af1b48514fc807a64605ec6371ee42290ba12e8
Make OCProcessEvent method.

OCProcess() need to poll periodically to check if any
work to process. This can be burden in some cases.
OCProcessEvent can get wake-up time using out parameter.
So we can use timed_wait not polling every periodic seconds.
To wake up for handling any receive event, we need to register
oc_event and this will send a signal to waited one.

Following patches are taken frm 2.0-rel branch :

1. https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/385
2. https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/393
3. https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/401
4. https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/431
5. https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/450
6. https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/470

https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/479
(cherry picked from 7ced5d4ee1b0fc3ee3cf0f4478f8df085b540b8e)

Change-Id: I27d1e17dcf21c5a45a7ff4a8b1a988b5c5edaf0a
Signed-off-by: kush.agrawal <kush.agrawal@samsung.com>
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
28 files changed:
build_common/SConscript [changed mode: 0644->0755]
resource/c_common/SConscript [changed mode: 0644->0755]
resource/c_common/iotivity_debug.h [new file with mode: 0755]
resource/c_common/ocevent/include/ocevent.h [new file with mode: 0755]
resource/c_common/ocevent/src/others/ocevent.c [new file with mode: 0755]
resource/c_common/ocevent/src/windows/ocevent.c [new file with mode: 0755]
resource/c_common/ocevent/test/SConscript [new file with mode: 0755]
resource/c_common/ocevent/test/eventtest.cpp [new file with mode: 0755]
resource/c_common/octhread/include/octhread.h [changed mode: 0644->0755]
resource/c_common/octhread/src/noop/octhread.c [changed mode: 0644->0755]
resource/c_common/octhread/src/posix/octhread.c [changed mode: 0644->0755]
resource/c_common/octhread/src/windows/octhread.c [changed mode: 0644->0755]
resource/csdk/connectivity/api/cacommon.h
resource/csdk/connectivity/api/cainterface.h [changed mode: 0644->0755]
resource/csdk/connectivity/inc/camessagehandler.h [changed mode: 0644->0755]
resource/csdk/connectivity/src/caconnectivitymanager.c [changed mode: 0644->0755]
resource/csdk/connectivity/src/camessagehandler.c
resource/csdk/routing/src/routingmanager.c [changed mode: 0644->0755]
resource/csdk/stack/include/internal/ocstackinternal.h [changed mode: 0644->0755]
resource/csdk/stack/include/internal/oickeepaliveinternal.h [changed mode: 0644->0755]
resource/csdk/stack/include/ocstack.h [changed mode: 0644->0755]
resource/csdk/stack/samples/linux/SimpleClientServer/ocserver.cpp [changed mode: 0644->0755]
resource/csdk/stack/src/ocstack.c
resource/csdk/stack/src/oickeepalive.c [changed mode: 0644->0755]
resource/include/InProcClientWrapper.h [changed mode: 0644->0755]
resource/include/InProcServerWrapper.h [changed mode: 0644->0755]
resource/src/InProcClientWrapper.cpp [changed mode: 0644->0755]
resource/src/InProcServerWrapper.cpp [changed mode: 0644->0755]