Fix rand initialization, add etcd connection/disconnection logging

This commit is contained in:
Vitaliy Filippov
2022-01-20 00:45:49 +03:00
parent a43ef525a2
commit 098e369a3b
3 changed files with 22 additions and 2 deletions
+3 -1
View File
@@ -58,7 +58,9 @@ msgr_rdma_context_t *msgr_rdma_context_t::create(const char *ib_devname, uint8_t
msgr_rdma_context_t *ctx = new msgr_rdma_context_t();
ctx->mtu = mtu;
srand48(time(NULL));
timespec tv;
clock_gettime(CLOCK_REALTIME, &tv);
srand48(tv.tv_sec*1000000000 + tv.tv_nsec);
dev_list = ibv_get_device_list(NULL);
if (!dev_list)
{