Fix: check for sizeof sa_family to save sa_family in accept and connect
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Wed, 31 Aug 2016 04:18:29 +0000 (00:18 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 31 Aug 2016 15:33:10 +0000 (11:33 -0400)
commit5a561ac39cd77ecda3fbdb2bfaafac56b174225c
treee9c25c645f434a4876970fb1e145b8e46af6a34e
parente36de50dd09527901339797a61a0a40d241c1a6d
Fix: check for sizeof sa_family to save sa_family in accept and connect

The check of addrlen >= sizeof(struct sockaddr) is too restrictive
and causes sa_family to not be saved in the case of AF_UNIX sockets
as the addrlen returned by the syscall may be only sizeof(short).

Individual checks per socket family are performed anyhow in the
switch case, making this safe.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
instrumentation/syscalls/headers/x86-64-syscalls-3.10.0-rc7_pointers_override.h
This page took 0.02572 seconds and 4 git commands to generate.