From: Hwankyu Jhun Date: Fri, 3 Apr 2020 03:59:10 +0000 (+0900) Subject: Convert error value X-Git-Tag: submit/tizen/20200408.034535~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=86334fa85c64abe9aa135daae6bef178c2a3e6bb;p=platform%2Fcore%2Fappfw%2Faul-1.git Convert error value Before returning the functions, the error value has to be converted by AUL error values. Change-Id: If7c430e6212909509bb564607be7e74db7b80f2c Signed-off-by: Hwankyu Jhun --- diff --git a/src/aul_rpc_port.c b/src/aul_rpc_port.c index 2fe6279..fa22ee1 100644 --- a/src/aul_rpc_port.c +++ b/src/aul_rpc_port.c @@ -20,11 +20,12 @@ #include #include +#include "aul.h" #include "aul_api.h" -#include "aul_util.h" -#include "aul_sock.h" +#include "aul_error.h" #include "aul_rpc_port.h" -#include "aul.h" +#include "aul_sock.h" +#include "aul_util.h" static bundle *__create_bundle(const char *appid, const char *port_name) { @@ -74,7 +75,7 @@ API int aul_rpc_port_prepare_stub(const char *appid, const char *port_name) _E("Failed to send request(%d:%s)", RPC_PORT_PREPARE_STUB, appid); bundle_free(b); - return r; + return aul_error_convert(r); } bundle_free(b); @@ -102,14 +103,14 @@ API int aul_rpc_port_create_socket_pair(const char *appid, if (fd <= 0 || fd > sysconf(_SC_OPEN_MAX)) { _E("Failed to send socket pair creation request. err = %d", fd); bundle_free(b); - return fd; + return aul_error_convert(fd); } bundle_free(b); r = aul_sock_recv_reply_sock_fd(fd, fds, 2); if (r != 0) { _E("Failed to receive socket fds. err = %d", r); - return r; + return aul_error_convert(r); } return AUL_R_OK; @@ -140,7 +141,7 @@ API int aul_rpc_port_notify_rpc_finished(void) if (r != 0) { _E("Failed to notify rpc finished(%d). err = %d", getpid(), r); bundle_free(b); - return r; + return aul_error_convert(r); } bundle_free(b);