From: Willem Jan Withagen Date: Sat, 3 Dec 2016 19:07:30 +0000 (+0100) Subject: rgw/rgw_main.cc: fix parenteses and function result X-Git-Tag: v12.0.1~321^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=6776fab00d7dac7a816fdc0f453cf10b727e79c9;p=ceph.git rgw/rgw_main.cc: fix parenteses and function result - The function in the macro parameter is expected to return -1 i on error and not type(bool). So reorganize the parenteses and just pass dup2() to the macro. Signed-off-by: Willem Jan Withagen --- diff --git a/src/rgw/rgw_main.cc b/src/rgw/rgw_main.cc index 09e650e1dbd6..a4a141f35350 100644 --- a/src/rgw/rgw_main.cc +++ b/src/rgw/rgw_main.cc @@ -196,7 +196,7 @@ int main(int argc, const char **argv) // dout() messages will be sent to stderr, but FCGX wants messages on stdout // Redirect stderr to stdout. TEMP_FAILURE_RETRY(close(STDERR_FILENO)); - if (TEMP_FAILURE_RETRY(dup2(STDOUT_FILENO, STDERR_FILENO) < 0)) { + if (TEMP_FAILURE_RETRY(dup2(STDOUT_FILENO, STDERR_FILENO)) < 0) { int err = errno; cout << "failed to redirect stderr to stdout: " << cpp_strerror(err) << std::endl;