summaryrefslogtreecommitdiff
path: root/test/media_device/media_device_test.cpp
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-07-02 00:58:53 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-07-02 02:37:18 +0300
commitf137451817f47c0bfe59586afe5af7b51f8ccad4 (patch)
tree4fa3220f1a67a506c132bd308bcf97b66ef39e2b /test/media_device/media_device_test.cpp
parenta00fdabacdd093c3eccb3d44155e151f59d783bf (diff)
libcamera: ipc: unix: Make socket operation asynchronous
Blocking socket operation when receiving messages may lead to long delays, and possibly a complete deadlock, if the remote side delays sending of the payload after the header, or doesn't send the payload at all. To avoid this, make the socket non-blocking and implement a simple state machine to receive the header synchronously with the socket read notification. The payload read is still synchronous with the receive() method to avoid data copies. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'test/media_device/media_device_test.cpp')
0 files changed, 0 insertions, 0 deletions