You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ji...@apache.org on 2016/10/13 05:34:44 UTC

[6/7] mesos git commit: Added 'stout/wait.hpp' header.

Added 'stout/wait.hpp' header.

This was motivated by the need for a default definition of
'W_EXITCODE' (since it is not technically POSIX compliant).

Review: https://reviews.apache.org/r/52705/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/fa56d045
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/fa56d045
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/fa56d045

Branch: refs/heads/master
Commit: fa56d0458860b2b7f035c793a192d7b55180a125
Parents: de69a72
Author: Kevin Klues <kl...@gmail.com>
Authored: Wed Oct 12 22:34:21 2016 -0700
Committer: Jie Yu <yu...@gmail.com>
Committed: Wed Oct 12 22:34:21 2016 -0700

----------------------------------------------------------------------
 3rdparty/stout/include/Makefile.am       |  1 +
 3rdparty/stout/include/stout/os/wait.hpp | 37 +++++++++++++++++++++++++++
 2 files changed, 38 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/fa56d045/3rdparty/stout/include/Makefile.am
----------------------------------------------------------------------
diff --git a/3rdparty/stout/include/Makefile.am b/3rdparty/stout/include/Makefile.am
index b0b08d8..1eb9c14 100644
--- a/3rdparty/stout/include/Makefile.am
+++ b/3rdparty/stout/include/Makefile.am
@@ -102,6 +102,7 @@ nobase_include_HEADERS =			\
   stout/os/sysctl.hpp				\
   stout/os/touch.hpp				\
   stout/os/utime.hpp				\
+  stout/os/wait.hpp				\
   stout/os/write.hpp				\
   stout/os/posix/bootid.hpp			\
   stout/os/posix/chown.hpp			\

http://git-wip-us.apache.org/repos/asf/mesos/blob/fa56d045/3rdparty/stout/include/stout/os/wait.hpp
----------------------------------------------------------------------
diff --git a/3rdparty/stout/include/stout/os/wait.hpp b/3rdparty/stout/include/stout/os/wait.hpp
new file mode 100644
index 0000000..06cf10c
--- /dev/null
+++ b/3rdparty/stout/include/stout/os/wait.hpp
@@ -0,0 +1,37 @@
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//  http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#ifndef __STOUT_OS_WAIT_HPP__
+#define __STOUT_OS_WAIT_HPP__
+
+#ifdef __WINDOWS__
+// TODO(klueska): Move all `WAIT` related functions out of
+// `windows.hpp` and into this file.
+#include <windows.hpp>
+#else
+#include <sys/wait.h>
+#endif // __WINDOWS__
+
+
+#ifndef W_EXITCODE
+#define W_EXITCODE(ret, sig)  ((ret) << 8 | (sig))
+#endif
+
+
+namespace os {
+
+// TODO(klueska): Add helper functions for common wait related
+// operations in this header file.
+
+} // namespace os {
+
+#endif // __STOUT_OS_WAIT_HPP__