Re: Review Request 53708: Remove warnings from `duration.hpp`.

2016-12-07 Thread Joseph Wu

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




3rdparty/stout/include/stout/duration.hpp (lines 99 - 100)


These two types are supposed to be `time_t` and `suseconds_t`.

This code is odd in that `secs()` and `us()` will cast an `int` to `double` 
and back to `int`.  Better to just do:
```
t.tv_sec = ns() / SECONDS;
t.tv_usec = us() / MICROSECONDS - t.tv_sec * MILLISECONDS;
```


- Joseph Wu


On Nov. 13, 2016, 9:45 p.m., Daniel Pravat wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53708/
> ---
> 
> (Updated Nov. 13, 2016, 9:45 p.m.)
> 
> 
> Review request for mesos, Alex Naparu, Artem Harutyunyan, Alex Clemmer, 
> Joseph Wu, and Michael Park.
> 
> 
> Repository: mesos
> 
> 
> Description
> ---
> 
> Remove warnings from `duration.hpp`.
> 
> 
> Diffs
> -
> 
>   3rdparty/stout/include/stout/duration.hpp 
> 0a30a09678c20937caa6f094c3c63a326e357932 
> 
> Diff: https://reviews.apache.org/r/53708/diff/
> 
> 
> Testing
> ---
> 
> 
> Thanks,
> 
> Daniel Pravat
> 
>



Review Request 53708: Remove warnings from `duration.hpp`.

2016-11-13 Thread Daniel Pravat

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

Review request for mesos, Alex Naparu, Artem Harutyunyan, Alex Clemmer, Joseph 
Wu, and Michael Park.


Repository: mesos


Description
---

Remove warnings from `duration.hpp`.


Diffs
-

  3rdparty/stout/include/stout/duration.hpp 
0a30a09678c20937caa6f094c3c63a326e357932 

Diff: https://reviews.apache.org/r/53708/diff/


Testing
---


Thanks,

Daniel Pravat