Commit ec25c623 authored by Arash Sahbafard's avatar Arash Sahbafard Committed by Robert Schmidt

Fix: check RFsim bind() return code

parent 4940146f
......@@ -547,7 +547,8 @@ sin_port:
sin_addr:
{ s_addr: INADDR_ANY }
};
bind(t->listen_sock, (struct sockaddr *)&addr, sizeof(addr));
int rc = bind(t->listen_sock, (struct sockaddr *)&addr, sizeof(addr));
AssertFatal(rc == 0, "bind failed: errno %d, %s", errno, strerror(errno));
AssertFatal(listen(t->listen_sock, 5) == 0, "");
struct epoll_event ev= {0};
ev.events = EPOLLIN;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment