diff options
author | Timo Teräs <timo.teras@iki.fi> | 2016-02-16 06:16:38 +0000 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2016-02-16 06:16:38 +0000 |
commit | 8daae2d91da7ea2065b57e71950970efbeba80a2 (patch) | |
tree | cf4e8ec07e53ecc83f1fce05dd0b56a71234ce07 /main/musl/0003-getnameinfo-make-size-check-not-fail-for-bigger-size.patch | |
parent | b794eecf4cda65b993101985b5cbacf1ee263a12 (diff) | |
download | aports-8daae2d91da7ea2065b57e71950970efbeba80a2.tar.bz2 aports-8daae2d91da7ea2065b57e71950970efbeba80a2.tar.xz |
main/musl: upgrade to 1.1.13
Diffstat (limited to 'main/musl/0003-getnameinfo-make-size-check-not-fail-for-bigger-size.patch')
-rw-r--r-- | main/musl/0003-getnameinfo-make-size-check-not-fail-for-bigger-size.patch | 45 |
1 files changed, 0 insertions, 45 deletions
diff --git a/main/musl/0003-getnameinfo-make-size-check-not-fail-for-bigger-size.patch b/main/musl/0003-getnameinfo-make-size-check-not-fail-for-bigger-size.patch deleted file mode 100644 index 1b4192a740..0000000000 --- a/main/musl/0003-getnameinfo-make-size-check-not-fail-for-bigger-size.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 6eada2edb302ff061be8546b23c9cb836621d122 Mon Sep 17 00:00:00 2001 -From: Hauke Mehrtens <hauke@hauke-m.de> -Date: Mon, 26 Oct 2015 23:03:55 +0100 -Subject: [PATCH] getnameinfo: make size check not fail for bigger sizes - -getnameinfo() compares the size of the given struct sockaddr with -sizeof(struct sockaddr_in) and sizeof(struct sockaddr_in6) depending on -the net family. When you add a sockaddr of size sizeof(struct -sockaddr_storage) this function will fail because the size of the -sockaddr is too big. Change the check that it only fails if the size is -too small, but make it work when it is too big for example when someone -calls this function with a struct sockaddr_storage and its size. -This fixes a problem with IoTivity 1.0.0 and musl. - -glibc and bionic are only failing if it is smaller, net/freebsd -implemented the != check. - -Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> ---- - src/network/getnameinfo.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/src/network/getnameinfo.c b/src/network/getnameinfo.c -index 3484fc6..5e6fae3 100644 ---- a/src/network/getnameinfo.c -+++ b/src/network/getnameinfo.c -@@ -135,13 +135,13 @@ int getnameinfo(const struct sockaddr *restrict sa, socklen_t sl, - switch (af) { - case AF_INET: - a = (void *)&((struct sockaddr_in *)sa)->sin_addr; -- if (sl != sizeof(struct sockaddr_in)) return EAI_FAMILY; -+ if (sl < sizeof(struct sockaddr_in)) return EAI_FAMILY; - mkptr4(ptr, a); - scopeid = 0; - break; - case AF_INET6: - a = (void *)&((struct sockaddr_in6 *)sa)->sin6_addr; -- if (sl != sizeof(struct sockaddr_in6)) return EAI_FAMILY; -+ if (sl < sizeof(struct sockaddr_in6)) return EAI_FAMILY; - if (memcmp(a, "\0\0\0\0\0\0\0\0\0\0\xff\xff", 12)) - mkptr6(ptr, a); - else --- -2.7.0 - |