summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-08-17 06:09:35 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-08-18 01:32:27 +0300
commitd0d1733027c16aa3fe9b7427b4a00a126ebbc6ba (patch)
tree865489c7bfc2ba590f8e3958afe2062abd9b213d /utils
parent5b7d16dc1f3d4aaf759a82082b162ab1d25d1f99 (diff)
utils: ipc: ipa_proxy_worker: Log IPCUnixSocket::send() failures
The IPCUnixSocket::send() function may fail, in which case it can be useful for debugging to log an error message that tells which event was affected. Do so. Reported-by: Coverity CID=35483[6-9] Reported-by: Coverity CID=35484[01] Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com> Reviewed-by: Umang Jain <umang.jain@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'utils')
-rw-r--r--utils/ipc/generators/libcamera_templates/module_ipa_proxy_worker.cpp.tmpl5
1 files changed, 4 insertions, 1 deletions
diff --git a/utils/ipc/generators/libcamera_templates/module_ipa_proxy_worker.cpp.tmpl b/utils/ipc/generators/libcamera_templates/module_ipa_proxy_worker.cpp.tmpl
index 164a4dd6..8a88bd46 100644
--- a/utils/ipc/generators/libcamera_templates/module_ipa_proxy_worker.cpp.tmpl
+++ b/utils/ipc/generators/libcamera_templates/module_ipa_proxy_worker.cpp.tmpl
@@ -164,7 +164,10 @@ private:
{{proxy_funcs.serialize_call(method|method_param_inputs, "_message.data()", "_message.fds()")}}
- socket_.send(_message.payload());
+ int _ret = socket_.send(_message.payload());
+ if (_ret < 0)
+ LOG({{proxy_worker_name}}, Error)
+ << "Sending event {{method.mojom_name}}() failed: " << _ret;
LOG({{proxy_worker_name}}, Debug) << "{{method.mojom_name}} done";
}