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



3rdparty/libprocess/3rdparty/stout/include/stout/internal/windows/reparsepoint.hpp
 (line 108)
<https://reviews.apache.org/r/39803/#comment175503>

    Remove newline.



3rdparty/libprocess/3rdparty/stout/include/stout/internal/windows/reparsepoint.hpp
 (line 123)
<https://reviews.apache.org/r/39803/#comment175504>

    Remove newline.



3rdparty/libprocess/3rdparty/stout/include/stout/internal/windows/reparsepoint.hpp
 (lines 128 - 147)
<https://reviews.apache.org/r/39803/#comment175512>

    I would suggest something like the following:
    
    ```
      const WCHAR* substituteName =
        data.SymbolicLinkReparseBuffer.PathBuffer +
        data.SymbolicLinkReparseBuffer.SubstituteNameOffset / sizeof(WCHAR);
      const size_t substituteNameLength =
        data.SymbolicLinkReparseBuffer.SubstituteNameLength / sizeof(WCHAR);
    
      const WCHAR* printName =
        data.SymbolicLinkReparseBuffer.PathBuffer +
        data.SymbolicLinkReparseBuffer.PrintNameOffset / sizeof(WCHAR);
      const size_t printNameLength =
        data.SymbolicLinkReparseBuffer.PrintNameLength / sizeof(WCHAR);
    
      return SymbolicLink{
          std::wstring(substituteName, substituteNameLength),
          std::wstring(printName, printNameLength),
          data.SymbolicLinkReparseBuffer.Flags};
    ```
    
    The parts I care about are: (1) `s/int/size_t` for indices/lengths, (2) 
removing the `struct` in `struct SymbolicLink`, and (3) constructing 
`SymbolicLink` in-place.
    
    I don't think the index is worth saving.
    
    But this is probably more of a personal taste. So just take parts of it 
that you like.



3rdparty/libprocess/3rdparty/stout/include/stout/internal/windows/reparsepoint.hpp
 (lines 190 - 191)
<https://reviews.apache.org/r/39803/#comment175505>

    ```
    return WindowsError(
        "Could not open handle for symlink at path '" + absolutePath + "'");
    ```



3rdparty/libprocess/3rdparty/stout/include/stout/os/windows/stat.hpp (line 27)
<https://reviews.apache.org/r/39803/#comment175509>

    `s/time_t/`time_t`/`



3rdparty/libprocess/3rdparty/stout/include/stout/os/windows/stat.hpp (lines 40 
- 41)
<https://reviews.apache.org/r/39803/#comment175507>

    Add new line.



3rdparty/libprocess/3rdparty/stout/include/stout/os/windows/stat.hpp (lines 51 
- 52)
<https://reviews.apache.org/r/39803/#comment175508>

    Add new line.



3rdparty/libprocess/3rdparty/stout/include/stout/windows.hpp (lines 166 - 169)
<https://reviews.apache.org/r/39803/#comment175502>

    Is this supposed to return `int` like the ones below? or are they supposed 
to return `bool`?


- Michael Park


On Jan. 15, 2016, 1:58 a.m., Alex Clemmer wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/39803/
> -----------------------------------------------------------
> 
> (Updated Jan. 15, 2016, 1:58 a.m.)
> 
> 
> Review request for mesos, Artem Harutyunyan, Michael Hopcroft, Joris Van 
> Remoortere, and Joseph Wu.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Windows: Implemented stout/os/stat.hpp`.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/3rdparty/stout/include/Makefile.am 
> ec851dcb08d938defeb6066810011e003d594b29 
>   
> 3rdparty/libprocess/3rdparty/stout/include/stout/internal/windows/reparsepoint.hpp
>  PRE-CREATION 
>   
> 3rdparty/libprocess/3rdparty/stout/include/stout/internal/windows/symlink.hpp 
> PRE-CREATION 
>   3rdparty/libprocess/3rdparty/stout/include/stout/os/posix/stat.hpp 
> ffe074830ef90f492990bf695e686c885b9a155c 
>   3rdparty/libprocess/3rdparty/stout/include/stout/os/windows/stat.hpp 
> 5b38b9af654d7d1c574f0cc573083b66693ced1d 
>   3rdparty/libprocess/3rdparty/stout/include/stout/windows.hpp 
> 27edf1b4f8647a2720f2962eafa110d694b3baed 
> 
> Diff: https://reviews.apache.org/r/39803/diff/
> 
> 
> Testing
> -------
> 
> `make check` from autotools on Ubuntu 15.
> `make check` from CMake on OS X 10.10.
> Ran `check` project in VS on Windows 10.
> 
> 
> Thanks,
> 
> Alex Clemmer
> 
>

Reply via email to