upstream: struct sockaddr_storage is guaranteed to be large enough,

no need to check the size. OK kn, deraadt

OpenBSD-Commit-ID: 0aa56e92eb49c79f495b31a5093109ec5841f439
This commit is contained in:
florian@openbsd.org 2018-10-15 11:28:50 +00:00 committed by Damien Miller
parent aede1c3424
commit 83b3d99d2b
1 changed files with 1 additions and 5 deletions

View File

@ -1,4 +1,4 @@
/* $OpenBSD: sshconnect.c,v 1.305 2018/09/20 03:30:44 djm Exp $ */
/* $OpenBSD: sshconnect.c,v 1.306 2018/10/15 11:28:50 florian Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@ -369,10 +369,6 @@ ssh_create_socket(struct addrinfo *ai)
error("getaddrinfo: no addrs");
goto fail;
}
if (res->ai_addrlen > sizeof(bindaddr)) {
error("%s: addr doesn't fit", __func__);
goto fail;
}
memcpy(&bindaddr, res->ai_addr, res->ai_addrlen);
bindaddrlen = res->ai_addrlen;
} else if (options.bind_interface != NULL) {