Fix getsockopt() to use the correct len.