Fix problem of accept() not accepting a bigger buffer for the sockaddr then required (cupsd exposed this bug)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23420 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ithamar R. Adema
2008-01-11 22:12:50 +00:00
parent 57a393d2f9
commit fac155d491
@@ -84,7 +84,7 @@ check_args_and_address(ArgType &args, sockaddr_storage &address, void *data, siz
if (user_memcpy(&args, data, sizeof(ArgType)) < B_OK)
return B_BAD_ADDRESS;
if (args.address_length > sizeof(sockaddr_storage))
if (copyAddress && args.address_length > sizeof(sockaddr_storage))
return B_BAD_VALUE;
if (copyAddress && user_memcpy(&address, args.address, args.address_length) < B_OK)