> On March 20, 2017, 8:52 p.m., Joseph Wu wrote:
> > src/checks/checker.cpp
> > Lines 440-443 (original), 440-448 (patched)
> > <https://reviews.apache.org/r/57775/diff/2/?file=1668401#file1668401line440>
> >
> >     I'm guessing there's something in this chain that necessitates this 
> > change.  Can you explain?
> >     
> >     At a glance, these macros should work on Windows:
> >     ```
> >     #ifndef WIFEXITED
> >     #define WIFEXITED(x) ((x) != -1)
> >     #endif // WIFEXITED
> >     
> >     #ifndef WEXITSTATUS
> >     #define WEXITSTATUS(x) (x & 0xFF)
> >     #endif // WEXITSTATUS
> >     ```
> 
> Alexander Rukletsov wrote:
>     We would like to return the exit code of the check, see 
> https://github.com/apache/mesos/blob/05e9a1d40572b8383a582e15663d861b134a7dad/include/mesos/mesos.proto#L1738-L1743
>  . We obviously want something portable, so that schedulers don't have to 
> interpret this value differently based on the OS the agent is running on. 
> However, AFAIK the way exit code is obtained differs on Unix and Windows, see 
> https://issues.apache.org/jira/browse/MESOS-7242. Your macros look fine at a 
> first glance, but I don't want to introduce them locally. Can we tackle this 
> problem in general and fix MESOS-7242 instead?

Looks like these macros are already available in "stout/windows.hpp". I'm 
discarding the patch for now.


- Alexander


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/57775/#review169499
-----------------------------------------------------------


On March 23, 2017, 3:31 p.m., Alexander Rukletsov wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/57775/
> -----------------------------------------------------------
> 
> (Updated March 23, 2017, 3:31 p.m.)
> 
> 
> Review request for mesos, Andrew Schwartzmeyer, Gastón Kleiman, and Vinod 
> Kone.
> 
> 
> Bugs: MESOS-6906
>     https://issues.apache.org/jira/browse/MESOS-6906
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> See summary.
> 
> 
> Diffs
> -----
> 
>   src/checks/checker.cpp 314354cc374b453ec12e25e3d4730a92697468cf 
> 
> 
> Diff: https://reviews.apache.org/r/57775/diff/4/
> 
> 
> Testing
> -------
> 
> make check on Linux and Windows
> 
> 
> Thanks,
> 
> Alexander Rukletsov
> 
>

Reply via email to