MCPcopy Create free account
hub / github.com/ElementsProject/lightning / time_now

Function time_now

ccan/ccan/time/time.c:9–17  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7#include <sys/time.h>
8
9struct timeabs time_now(void)
10{
11 struct timeval now;
12 struct timeabs ret;
13 gettimeofday(&now, NULL);
14 ret.ts.tv_sec = now.tv_sec;
15 ret.ts.tv_nsec = now.tv_usec * 1000;
16 return TIMEABS_CHECK(ret);
17}
18#else
19#include <time.h>
20struct timeabs time_now(void)

Callers 15

update_recent_timestampFunction · 0.85
send_pingFunction · 0.85
read_body_from_peer_doneFunction · 0.85
new_peerFunction · 0.85
gossip_store_loadFunction · 0.85
gossip_time_nowFunction · 0.85
mainFunction · 0.85
const_time_testFunction · 0.85
nonconst_time_testFunction · 0.85

Calls

no outgoing calls

Tested by 5

mainFunction · 0.68
const_time_testFunction · 0.68
nonconst_time_testFunction · 0.68
mainFunction · 0.68
mainFunction · 0.68