From: t3sserakt Date: Wed, 29 Jan 2020 18:16:33 +0000 (+0100) Subject: update last_connection_create X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=3e509e06339aae2643bd33db06e8b3d6f90a5235;p=oweals%2Fgnunet.git update last_connection_create --- diff --git a/src/cadet/gnunet-service-cadet_peer.c b/src/cadet/gnunet-service-cadet_peer.c index 475e60ddb..2376d6af5 100644 --- a/src/cadet/gnunet-service-cadet_peer.c +++ b/src/cadet/gnunet-service-cadet_peer.c @@ -1567,9 +1567,13 @@ GCP_update_monotime (struct CadetPeer *peer) int GCP_check_monotime (struct CadetPeer *peer, struct GNUNET_TIME_AbsoluteNBO monotime) { + + struct GNUNET_TIME_Absolute mt = GNUNET_TIME_absolute_ntoh(monotime); - if (GNUNET_TIME_absolute_ntoh(monotime).abs_value_us > *(&peer->last_connection_create.abs_value_us)) + if (mt.abs_value_us > *(&peer->last_connection_create.abs_value_us)){ + peer->last_connection_create = mt; return GNUNET_YES; + } return GNUNET_NO; }