Skip to content

Commit 9334e1e

Browse files
committed
add error handling to bind
1 parent 69c07d1 commit 9334e1e

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/core/connection.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,9 @@ int connection_open_listener(struct scache_bind ibind) {
153153
memset(&unaddr, 0, sizeof(unaddr));
154154
unaddr.sun_family = ibind.af;
155155
memcpy(&unaddr.sun_path, &ibind.addr, sizeof(unaddr.sun_path));
156+
157+
default:
158+
FATAL("Unknown address family, cant bind");
156159
}
157160

158161
res = bind(listenfd, tobind, tobind_len);

0 commit comments

Comments
 (0)