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

Function time_from_sec

ccan/ccan/time/time.h:611–618  ·  view source on GitHub ↗

* time_from_sec - convert seconds to a relative time * @msec: time in seconds * * Example: * // 1 minute timeout * #define TIMEOUT time_from_sec(60) */

Source from the content-addressed store, hash-verified

609 * #define TIMEOUT time_from_sec(60)
610 */
611static inline struct timerel time_from_sec(uint64_t sec)
612{
613 struct timerel t;
614
615 t.ts.tv_nsec = 0;
616 t.ts.tv_sec = sec;
617 return TIMEREL_CHECK(t);
618}
619
620/**
621 * time_from_msec - convert milliseconds to a relative time

Callers 15

drain_peerFunction · 0.85
gossip_stream_timerFunction · 0.85
set_ping_timerFunction · 0.85
send_pingFunction · 0.85
conn_inFunction · 0.85
connection_outFunction · 0.85
gossip_refresh_networkFunction · 0.85
gossip_initFunction · 0.85
begin_check_timerFunction · 0.85
defer_updateFunction · 0.85

Calls

no outgoing calls

Tested by 4

mainFunction · 0.68
mainFunction · 0.68
mainFunction · 0.68
mainFunction · 0.68