summaryrefslogtreecommitdiff
path: root/networking/isrv.c
diff options
context:
space:
mode:
authorDenys Vlasenko2015-10-13 14:50:20 +0200
committerDenys Vlasenko2015-10-13 14:50:20 +0200
commitab3964db4e75e34f6f9347406c5fd2bced04f2dd (patch)
tree92113e4a008338ed8534858db97d3a5e09dc210b /networking/isrv.c
parentf7ad927c2059ef9cd1cd6befeb43f26b92f6369f (diff)
downloadbusybox-ab3964db4e75e34f6f9347406c5fd2bced04f2dd.zip
busybox-ab3964db4e75e34f6f9347406c5fd2bced04f2dd.tar.gz
libbb: introduce kernel-style BUILD_BUG_ON()
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/isrv.c')
-rw-r--r--networking/isrv.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/networking/isrv.c b/networking/isrv.c
index 1c6491e..3673db7 100644
--- a/networking/isrv.c
+++ b/networking/isrv.c
@@ -194,7 +194,6 @@ static void handle_accept(isrv_state_t *state, int fd)
remove_peer(state, n); /* unsuccesful peer start */
}
-void BUG_sizeof_fd_set_is_strange(void);
static void handle_fd_set(isrv_state_t *state, fd_set *fds, int (*h)(int, void **))
{
enum { LONG_CNT = sizeof(fd_set) / sizeof(long) };
@@ -203,8 +202,7 @@ static void handle_fd_set(isrv_state_t *state, fd_set *fds, int (*h)(int, void *
/* need to know value at _the beginning_ of this routine */
int fd_cnt = FD_COUNT;
- if (LONG_CNT * sizeof(long) != sizeof(fd_set))
- BUG_sizeof_fd_set_is_strange();
+ BUILD_BUG_ON(LONG_CNT * sizeof(long) != sizeof(fd_set));
fds_pos = 0;
while (1) {