diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2017-02-04 00:40:06 +0100 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2017-02-04 00:40:06 +0100 |
commit | 95bcbfdd4e96cc89791e8fa907a508ace339c4c1 (patch) | |
tree | 9f4ecbd604bd914dbc0725b3babc7781f5ec8957 /updater | |
parent | Merge "Avoid to call UI functions in child process" (diff) | |
parent | Replace _exit(-1) with _exit(EXIT_FAILURE). (diff) | |
download | android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.tar android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.tar.gz android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.tar.bz2 android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.tar.lz android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.tar.xz android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.tar.zst android_bootable_recovery-95bcbfdd4e96cc89791e8fa907a508ace339c4c1.zip |
Diffstat (limited to '')
-rw-r--r-- | updater/blockimg.cpp | 2 | ||||
-rw-r--r-- | updater/install.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/updater/blockimg.cpp b/updater/blockimg.cpp index 6755d78cb..03ce4136e 100644 --- a/updater/blockimg.cpp +++ b/updater/blockimg.cpp @@ -120,7 +120,7 @@ static RangeSet parse_range(const std::string& range_text) { err: LOG(ERROR) << "failed to parse range '" << range_text << "'"; - exit(1); + exit(EXIT_FAILURE); } static bool range_overlaps(const RangeSet& r1, const RangeSet& r2) { diff --git a/updater/install.cpp b/updater/install.cpp index 7a8e92f6c..c7ecdb5c7 100644 --- a/updater/install.cpp +++ b/updater/install.cpp @@ -247,7 +247,7 @@ static int exec_cmd(const char* path, char* const argv[]) { pid_t child; if ((child = vfork()) == 0) { execv(path, argv); - _exit(-1); + _exit(EXIT_FAILURE); } int status; @@ -1072,7 +1072,7 @@ Value* RunProgramFn(const char* name, State* state, int argc, Expr* argv[]) { if (child == 0) { execv(args2[0], args2); PLOG(ERROR) << "run_program: execv failed"; - _exit(1); + _exit(EXIT_FAILURE); } int status; |