Skip to content

Commit 4e3cfc1

Browse files
committed
Merge branch 'dev' of https://github.com/F-Stack/f-stack into dev
2 parents 813f226 + 8762e05 commit 4e3cfc1

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

adapter/syscall/ff_hook_syscall.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -437,6 +437,11 @@ ff_hook_bind(int fd, const struct sockaddr *addr,
437437
return -1;
438438
}
439439

440+
if (addrlen > sizeof(struct sockaddr_storage)) {
441+
errno = EINVAL;
442+
return -1;
443+
}
444+
440445
CHECK_FD_OWNERSHIP(bind, (fd, addr, addrlen));
441446

442447
DEFINE_REQ_ARGS(bind);

0 commit comments

Comments
 (0)