summaryrefslogtreecommitdiff
path: root/email-ipc/email-stub/email-stub-socket.c
diff options
context:
space:
mode:
Diffstat (limited to 'email-ipc/email-stub/email-stub-socket.c')
-rwxr-xr-xemail-ipc/email-stub/email-stub-socket.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/email-ipc/email-stub/email-stub-socket.c b/email-ipc/email-stub/email-stub-socket.c
index d018634..58f4b55 100755
--- a/email-ipc/email-stub/email-stub-socket.c
+++ b/email-ipc/email-stub/email-stub-socket.c
@@ -164,8 +164,8 @@ EXPORT_API void emipc_wait_for_ipc_request()
EM_DEBUG_LOG("[IPCLib]Stub Socket Recv [Socket ID = %d], [recv_len = %d]", event_fd, recv_len);
EM_DEBUG_LOG("====================================================================");
emipc_create_task((unsigned char *)sz_buf, event_fd);
- } else {
- EM_DEBUG_LOG("[IPCLib] Socket [%d] removed - [%d] ", event_fd, recv_len);
+ } else if( recv_len == 0 ) {
+ EM_DEBUG_LOG("[IPCLib] Client closed connection [%d]", event_fd);
epoll_ctl(epfd, EPOLL_CTL_DEL, event_fd, events);
close(event_fd);
}
@@ -181,7 +181,7 @@ EXPORT_API bool emipc_end_stub_socket()
EM_DEBUG_FUNC_BEGIN();
if (stub_socket) {
- emipc_close_email_socket(stub_socket);
+ emipc_close_email_socket(&stub_socket);
}
if (stub_socket_thread) {