From 86b19dbf8eebc88b09cbe3b94c49893cfc86d2b5 Mon Sep 17 00:00:00 2001 From: Praveen Kumar Date: Wed, 10 Jun 2015 15:21:07 -0700 Subject: [PATCH] Fix libc++ use Summary: Use of std::max from libc++ resulted in error. std::max found type of its arguments diffrent whereas it expected them to be same. This diff fix the error. Closes #223 Reviewed By: @yfeldblum Differential Revision: D2144639 Pulled By: @sgolemon --- folly/io/async/AsyncServerSocket.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/folly/io/async/AsyncServerSocket.cpp b/folly/io/async/AsyncServerSocket.cpp index 8520f464..34fa5c6f 100644 --- a/folly/io/async/AsyncServerSocket.cpp +++ b/folly/io/async/AsyncServerSocket.cpp @@ -726,8 +726,8 @@ void AsyncServerSocket::handlerReady( std::chrono::time_point nowMs = std::chrono::steady_clock::now(); - int64_t timeSinceLastAccept = std::max( - int64_t(0), + auto timeSinceLastAccept = std::max( + 0, nowMs.time_since_epoch().count() - lastAccepTimestamp_.time_since_epoch().count()); lastAccepTimestamp_ = nowMs; -- 2.34.1