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

Function sync_crypto_write

devtools/gossipwith.c:123–132  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

121}
122
123static void sync_crypto_write(int peer_fd, struct crypto_state *cs, const void *msg TAKES)
124{
125 u8 *enc;
126
127 enc = cryptomsg_encrypt_msg(NULL, cs, msg);
128
129 if (!write_all(peer_fd, enc, tal_count(enc)))
130 exit(1);
131 tal_free(enc);
132}
133
134static u8 *sync_crypto_read(const tal_t *ctx, int peer_fd, struct crypto_state *cs)
135{

Callers 1

handshake_successFunction · 0.85

Calls 3

cryptomsg_encrypt_msgFunction · 0.85
tal_freeFunction · 0.85
write_allFunction · 0.50

Tested by

no test coverage detected