projects
/
platform
/
core
/
appfw
/
rpc-port.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ce040b8
)
Handle EINTR error
93/309493/1
author
Hwankyu Jhun
<h.jhun@samsung.com>
Thu, 11 Apr 2024 10:40:02 +0000
(19:40 +0900)
committer
Hwankyu Jhun
<h.jhun@samsung.com>
Thu, 11 Apr 2024 10:40:02 +0000
(19:40 +0900)
Currently, the socket mode is blocking. We should handle EINTR error to
receive the data properly.
Change-Id: Icec0439bf547401b72575d05da513711513f4b54
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
src/client-socket-internal.cc
patch
|
blob
|
history
diff --git
a/src/client-socket-internal.cc
b/src/client-socket-internal.cc
index
08b2ae9
..
241e52d
100644
(file)
--- a/
src/client-socket-internal.cc
+++ b/
src/client-socket-internal.cc
@@
-115,6
+115,11
@@
int ClientSocket::Receive(void* buf, unsigned int size) {
return -EIO; // LCOV_EXCL_STOP
}
+ if (errno == EINTR) {
+ usleep(100 * 1000);
+ continue;
+ }
+
if (bytes < 0)
return -errno; // LCOV_EXCL_LINE