aboutsummaryrefslogtreecommitdiffstats
path: root/main/musl
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2014-09-05 12:24:50 +0300
committerTimo Teräs <timo.teras@iki.fi>2014-09-05 12:25:10 +0300
commit9d2b8346fd10ca352300a9c952538e865dce5a19 (patch)
tree5847732ec31319c70ea0d7f54ab990815b3811a5 /main/musl
parent9655d9e8c7ca193707ae9f15f60174e3e25602fb (diff)
downloadaports-9d2b8346fd10ca352300a9c952538e865dce5a19.tar.bz2
aports-9d2b8346fd10ca352300a9c952538e865dce5a19.tar.xz
main/musl: add few more commits from today, add funlockfile check
Diffstat (limited to 'main/musl')
-rw-r--r--main/musl/0004-6e2bb7ac-to-4674809b.patch68
-rw-r--r--main/musl/1002-check-lockcount-in-funlockfile.patch17
-rw-r--r--main/musl/APKBUILD10
3 files changed, 94 insertions, 1 deletions
diff --git a/main/musl/0004-6e2bb7ac-to-4674809b.patch b/main/musl/0004-6e2bb7ac-to-4674809b.patch
new file mode 100644
index 0000000000..62710e321c
--- /dev/null
+++ b/main/musl/0004-6e2bb7ac-to-4674809b.patch
@@ -0,0 +1,68 @@
+diff --git a/src/ctype/iswlower.c b/src/ctype/iswlower.c
+index c754fb9..79df44a 100644
+--- a/src/ctype/iswlower.c
++++ b/src/ctype/iswlower.c
+@@ -3,7 +3,7 @@
+
+ int iswlower(wint_t wc)
+ {
+- return towupper(wc) != wc || wc == 0xdf;
++ return towupper(wc) != wc;
+ }
+
+ int __iswlower_l(wint_t c, locale_t l)
+diff --git a/src/ctype/towctrans.c b/src/ctype/towctrans.c
+index 5e0889b..6af6187 100644
+--- a/src/ctype/towctrans.c
++++ b/src/ctype/towctrans.c
+@@ -151,7 +151,6 @@ static const unsigned short pairs[][2] = {
+ { 0x03f7, 0x03f8 },
+ { 0x03fa, 0x03fb },
+ { 0x1e60, 0x1e9b },
+- { 0xdf, 0xdf },
+ { 0x1e9e, 0xdf },
+
+ { 0x1f59, 0x1f51 },
+diff --git a/src/network/getnameinfo.c b/src/network/getnameinfo.c
+index 588ed76..2ba66e3 100644
+--- a/src/network/getnameinfo.c
++++ b/src/network/getnameinfo.c
+@@ -113,11 +113,10 @@ static void reverse_services(char *buf, int port, int dgram)
+
+ static int dns_parse_callback(void *c, int rr, const void *data, int len, const void *packet)
+ {
+- char tmp[256];
+ if (rr != RR_PTR) return 0;
+ if (__dn_expand(packet, (const unsigned char *)packet + 512,
+- data, tmp, sizeof tmp) > 0)
+- strcpy(c, tmp);
++ data, c, 256) <= 0)
++ *(char *)c = 0;
+ return 0;
+
+ }
+diff --git a/src/thread/pthread_join.c b/src/thread/pthread_join.c
+index 719c91c..abd2d66 100644
+--- a/src/thread/pthread_join.c
++++ b/src/thread/pthread_join.c
+@@ -8,6 +8,7 @@ static void dummy(void *p)
+ int pthread_join(pthread_t t, void **res)
+ {
+ int tmp;
++ pthread_testcancel();
+ while ((tmp = t->tid)) __timedwait(&t->tid, tmp, 0, 0, dummy, 0, 0);
+ if (res) *res = t->result;
+ if (t->map_base) munmap(t->map_base, t->map_size);
+diff --git a/src/thread/sem_timedwait.c b/src/thread/sem_timedwait.c
+index b5a60ad..68dcb50 100644
+--- a/src/thread/sem_timedwait.c
++++ b/src/thread/sem_timedwait.c
+@@ -8,6 +8,8 @@ static void cleanup(void *p)
+
+ int sem_timedwait(sem_t *restrict sem, const struct timespec *restrict at)
+ {
++ pthread_testcancel();
++
+ if (!sem_trywait(sem)) return 0;
+
+ int spins = 100;
diff --git a/main/musl/1002-check-lockcount-in-funlockfile.patch b/main/musl/1002-check-lockcount-in-funlockfile.patch
new file mode 100644
index 0000000000..a2ae3a1360
--- /dev/null
+++ b/main/musl/1002-check-lockcount-in-funlockfile.patch
@@ -0,0 +1,17 @@
+diff -ru musl-1.1.4.orig/src/stdio/funlockfile.c musl-1.1.4/src/stdio/funlockfile.c
+--- musl-1.1.4.orig/src/stdio/funlockfile.c 2014-09-05 11:58:04.928864395 -0300
++++ musl-1.1.4/src/stdio/funlockfile.c 2014-09-05 11:58:45.915533166 -0300
+@@ -1,10 +1,12 @@
+ #include "stdio_impl.h"
+ #include "pthread_impl.h"
++#include "atomic.h"
+
+ void __unlist_locked_file(FILE *);
+
+ void funlockfile(FILE *f)
+ {
++ if (f->lockcount == 0) a_crash();
+ if (f->lockcount == 1) {
+ __unlist_locked_file(f);
+ f->lockcount = 0;
+
diff --git a/main/musl/APKBUILD b/main/musl/APKBUILD
index 4705f3a974..8d6448720d 100644
--- a/main/musl/APKBUILD
+++ b/main/musl/APKBUILD
@@ -2,7 +2,7 @@
# Maintainer: Timo Teräs <timo.teras@iki.fi>
pkgname=musl
pkgver=1.1.4
-pkgrel=5
+pkgrel=6
pkgdesc="the musl c library (libc) implementation"
url="http://www.musl-libc.org/"
arch="all"
@@ -16,7 +16,9 @@ source="http://www.musl-libc.org/releases/musl-$pkgver.tar.gz
0001-v1.1.4-to-d86af2a0.patch
0002-d86af2a0-to-4992ace9.patch
0003-4992ace9-to-6e2bb7ac.patch
+ 0004-6e2bb7ac-to-4674809b.patch
1001-add-basic-dns-record-parsing-functions.patch
+ 1002-check-lockcount-in-funlockfile.patch
1003-remove-ulimit-fiddling-from-setxid.patch
ldconfig
@@ -124,7 +126,9 @@ md5sums="f18f3bdbe088438cd64a5313c19a7312 musl-1.1.4.tar.gz
7e6f4c4e0992f73d61963959d7fbbaa5 0001-v1.1.4-to-d86af2a0.patch
04eef5b44c0b56b79055340bee1febc2 0002-d86af2a0-to-4992ace9.patch
6710102c768f5a971b93100219de3fbb 0003-4992ace9-to-6e2bb7ac.patch
+294d3d382098977ea0770731a4803322 0004-6e2bb7ac-to-4674809b.patch
2371eb1ce057fcb709a0e6a81f0d356c 1001-add-basic-dns-record-parsing-functions.patch
+8a763b1853ee16d034abe038a0c44641 1002-check-lockcount-in-funlockfile.patch
71b2a4dcc39c436a6b89173943424043 1003-remove-ulimit-fiddling-from-setxid.patch
830d01f7821b978df770b06db3790921 ldconfig
61c6c1e84ed1df82abbe6d75e90cf21c getopt_long.c
@@ -136,7 +140,9 @@ sha256sums="658c65ad3c3a9b281a96c5281e75720c758d91fcaae35ab987f2fdfb4f88f5cd mu
2966fe530dfda4affca61375d16a4d03140ddf3beb39df90b9f5f0b10558eb5d 0001-v1.1.4-to-d86af2a0.patch
c7521464f3096befb5b44d303819e9169a43a6a5a3c93566ac1cdf523a6a389d 0002-d86af2a0-to-4992ace9.patch
7a716e03084724e3776300d8ed498e835b2cad4321b638a3eec5a9d8f28de8d9 0003-4992ace9-to-6e2bb7ac.patch
+e727b50aa65886563960c10449f60e229ffb94dd3476df1098e877ce599358c4 0004-6e2bb7ac-to-4674809b.patch
75053a31f6b84a64846d92c0ec631c76d7f747a9c0dc92a6dc1aa1bddfe2ea76 1001-add-basic-dns-record-parsing-functions.patch
+eebc0afce600cbe2f41055404c7735f1a7be6e262df602dbcbfde7321633bdd9 1002-check-lockcount-in-funlockfile.patch
fb542c2bd5081ff2f601c519edb3dac8f54ca5c888f44bc6cfb84e6565472025 1003-remove-ulimit-fiddling-from-setxid.patch
b4a2c06db38742e8c42c3c9838b285a7d8cdac6c091ff3df5ff9a15f1e41b9c7 ldconfig
d9b644ec20bc33e81a7c52b9fcf7973d835923a69faf50f03db45534b811bd96 getopt_long.c
@@ -148,7 +154,9 @@ sha512sums="a46fb1db23f518beaa959e9bebcb3bf0574e583c197792d30dcd52b3974e3c285594
6ef512bd4c05ae3a24493c4cffeac71953bb7383aaf88d2012f95b1e13dfa5f09ad3fc24b7f0d08e0d3788bcdf7195a1a8e639ec56b2ac01551a403398ac003e 0001-v1.1.4-to-d86af2a0.patch
0e892a0d0e2abf09cb52d27759769a4cdd39ebd87fb1af89f502da00a4c9453309291aeb69862d60d88a8d0a0c2517aabcc92b50214d67279b12113b3c5a0157 0002-d86af2a0-to-4992ace9.patch
af92b766d2ca9fcf58b57c705b65ec0b60ecd9af1d38f1b9697a6b999baa56d8cb0ecf94bc02267022a13763e4a1a13a3f73bc03fdf73c0cd8f80126c2949a13 0003-4992ace9-to-6e2bb7ac.patch
+8aa879e31c3eb18f9b00ea98d25872d94cad9120c05a80419965dcf7d3a4e0a69c370b35e2871cb11b639bbcf606842a48d3ad64ec916bc34b2eb21d3c4a3efa 0004-6e2bb7ac-to-4674809b.patch
5b8ffa0a50419581adbf6ce2dae5797774022551c6331fa5aa2ff13635eb72b74eedd8a92cb478d45d73e1956af2f588669681ac414f3a255abd4d8ba8579448 1001-add-basic-dns-record-parsing-functions.patch
+beb515f46fa7c18eafe72cc612c5e8877dd1fd083e05c427af3a2a4d4281df06c6c1727c39d136d8e3f267be8832ea133362f5088a2b6a26b33c9e184acf1884 1002-check-lockcount-in-funlockfile.patch
dae010b45419fcab64410568466f659cdc874e63113025e2cbc2fbab047b470fec23851ecbef08886505924482a069caf37c16b483b6922535fbd31832f1c4a3 1003-remove-ulimit-fiddling-from-setxid.patch
8d3a2d5315fc56fee7da9abb8b89bb38c6046c33d154c10d168fb35bfde6b0cf9f13042a3bceee34daf091bc409d699223735dcf19f382eeee1f6be34154f26f ldconfig
140f3f20d30bd95ebce8c41b8cc7f616c6cbedf4ea06c729c21014e74f6043796825cc40ebc5180620ea38173afdba23f09ebf6d8b11fa05440b14d23764fca9 getopt_long.c