aboutsummaryrefslogtreecommitdiffstats
path: root/community/connman/musl.patch
diff options
context:
space:
mode:
authorLeo <thinkabit.ukim@gmail.com>2019-09-25 00:26:33 -0300
committerLeo <thinkabit.ukim@gmail.com>2019-09-25 02:25:12 -0300
commit1de2bc50153409adff4fcc40fc54f0aeac2e0086 (patch)
treee08987579a1a4568fb7940795fb10f894226f049 /community/connman/musl.patch
parent21a5be955209203a84fdc7345a52fc4a43c0fed3 (diff)
community/connman: fix segfault with musl >= 1.1.21
fixes #10818
Diffstat (limited to 'community/connman/musl.patch')
-rw-r--r--community/connman/musl.patch18
1 files changed, 18 insertions, 0 deletions
diff --git a/community/connman/musl.patch b/community/connman/musl.patch
new file mode 100644
index 00000000000..f87807f360a
--- /dev/null
+++ b/community/connman/musl.patch
@@ -0,0 +1,18 @@
+In musl > 1.1.21 freeaddrinfo() implementation changed and
+was causing a segmentation fault.
+
+diff --git a/gweb/gweb.c b/gweb/gweb.c
+index 393afe0..12fcb1d 100644
+--- a/gweb/gweb.c
++++ b/gweb/gweb.c
+@@ -1274,7 +1274,8 @@ static bool is_ip_address(const char *host)
+ addr = NULL;
+
+ result = getaddrinfo(host, NULL, &hints, &addr);
+- freeaddrinfo(addr);
++ if(!result)
++ freeaddrinfo(addr);
+
+ return result == 0;
+ }
+