diff options
author | sangwan.kwon <sangwan.kwon@samsung.com> | 2016-03-15 16:39:07 +0900 |
---|---|---|
committer | sangwan.kwon <sangwan.kwon@samsung.com> | 2016-03-15 16:39:07 +0900 |
commit | 43c1e9355155d04a285a9a0d3fd67ef1d3cadc4a (patch) | |
tree | b19abe31b3db61b6d5e8c7f2376fc408418062ca | |
parent | 0460c95e1cddfc1e2453bf41a72230997b703835 (diff) | |
download | cert-checker-43c1e9355155d04a285a9a0d3fd67ef1d3cadc4a.tar.gz cert-checker-43c1e9355155d04a285a9a0d3fd67ef1d3cadc4a.tar.bz2 cert-checker-43c1e9355155d04a285a9a0d3fd67ef1d3cadc4a.zip |
Delete thread unsafe function. strerrorsubmit/tizen/20160321.051308accepted/tizen/wearable/20160321.113743accepted/tizen/tv/20160321.113723accepted/tizen/mobile/20160321.113706accepted/tizen/ivi/20160321.113800accepted/tizen/common/20160321.150604
* use GetErrnoString() instead of it
Change-Id: I0d767d423be26987d387ad1b1c5899d7f36a27b3
Signed-off-by: sangwan.kwon <sangwan.kwon@samsung.com>
-rw-r--r-- | src/ui/popup-bin/CMakeLists.txt | 5 | ||||
-rw-r--r-- | src/ui/popup-bin/popup.cpp | 8 |
2 files changed, 11 insertions, 2 deletions
diff --git a/src/ui/popup-bin/CMakeLists.txt b/src/ui/popup-bin/CMakeLists.txt index 2b89d2f..8c2ac68 100644 --- a/src/ui/popup-bin/CMakeLists.txt +++ b/src/ui/popup-bin/CMakeLists.txt @@ -34,7 +34,11 @@ set(CERT_CHECKER_POPUP_SOURCES # logs ${CERT_CHECKER_SRC_PATH}/log/log.cpp # dpl + ${CERT_CHECKER_SRC_PATH}/dpl/core/src/assert.cpp + ${CERT_CHECKER_SRC_PATH}/dpl/core/src/exception.cpp ${CERT_CHECKER_SRC_PATH}/dpl/core/src/serialization.cpp + ${CERT_CHECKER_SRC_PATH}/dpl/core/src/errno_string.cpp + ${CERT_CHECKER_SRC_PATH}/dpl/core/src/noncopyable.cpp ) ADD_DEFINITIONS(${CERT_CHECKER_POPUP_DEP_CFLAGS}) @@ -43,6 +47,7 @@ INCLUDE_DIRECTORIES( ${CERT_CHECKER_POPUP_SRC_DIR} ${CERT_CHECKER_POPUP_DEP_INCLUDE_DIRS} ${CERT_CHECKER_SRC_PATH}/include/ + ${CERT_CHECKER_SRC_PATH}/dpl/core/include/ ) ADD_EXECUTABLE(${TARGET_CERT_CHECKER_POPUP} diff --git a/src/ui/popup-bin/popup.cpp b/src/ui/popup-bin/popup.cpp index 6b3032a..019ef04 100644 --- a/src/ui/popup-bin/popup.cpp +++ b/src/ui/popup-bin/popup.cpp @@ -35,6 +35,7 @@ #include <cchecker/UIBackend.h> #include <cchecker/popup-runner.h> #include <cchecker/dpl/serialization.h> +#include <cchecker/dpl/errno_string.h> using namespace CCHECKER::UI; @@ -172,7 +173,9 @@ static int wait_for_parent_info (int pipe_in) int sel = select(pipe_in + 1, &readfds, NULL, NULL, &timeout); if (sel == -1) { - LogError("Cannot get info from parent. Exit popup - ERROR (" << errno << ")"); + int error = errno; + LogError("Cannot get info from parent. Exit popup"); + LogError("Error: " << CCHECKER::GetErrnoString(error)); close(pipe_in); return -1; } @@ -260,10 +263,11 @@ elm_main(int argc, char **argv) count = TEMP_FAILURE_RETRY(read(pipe_in, line, buff_size)); } while (0 == count); if(count < 0){ + int error = errno; close(pipe_in); close(pipe_out); LogError("read returned a negative value (" << count <<")"); - LogError("errno: " << strerror( errno ) ); + LogError("error: " << CCHECKER::GetErrnoString(error)); LogError("Exit popup - ERROR"); return popup_status::EXIT_ERROR; } |