Explorar el Código

Fix compile error with clang and --enable-werror

Tatsuhiro Tsujikawa hace 9 años
padre
commit
c245c5ecc6
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      src/DHTMessageTracker.cc

+ 2 - 1
src/DHTMessageTracker.cc

@@ -90,7 +90,8 @@ DHTMessageTracker::messageArrived(const Dict* dict, const std::string& ipaddr,
 
         auto rtt = std::chrono::duration_cast<std::chrono::milliseconds>(
             entry->getElapsed());
-        A2_LOG_DEBUG(fmt("RTT is %" PRId64 "", rtt.count()));
+        A2_LOG_DEBUG(
+            fmt("RTT is %" PRId64 "", static_cast<int64_t>(rtt.count())));
         message->getRemoteNode()->updateRTT(rtt);
         if (*targetNode != *message->getRemoteNode()) {
           // Node ID has changed. Drop previous node ID from