aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2015-06-05 10:47:34 +0300
committerTimo Teräs <timo.teras@iki.fi>2015-06-05 10:47:34 +0300
commit3a127bb22d1044e5e1a66a4e521f0841f62cdb26 (patch)
treea4c24f1732e5ec87d1832ff55ed54d8c7fc4e04f
parent585bfa9a7ba9d9e08d53b891bc6514605129ed1b (diff)
downloadaports-3a127bb22d1044e5e1a66a4e521f0841f62cdb26.tar.bz2
aports-3a127bb22d1044e5e1a66a4e521f0841f62cdb26.tar.xz
main/musl: fix locale regression in 1.1.10
-rw-r--r--main/musl/0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch29
-rw-r--r--main/musl/APKBUILD6
2 files changed, 34 insertions, 1 deletions
diff --git a/main/musl/0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch b/main/musl/0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch
new file mode 100644
index 0000000000..2e4370b555
--- /dev/null
+++ b/main/musl/0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch
@@ -0,0 +1,29 @@
+From bf8130a2843909df0d14cce5b5149cde35f887ac Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
+Date: Fri, 5 Jun 2015 10:39:42 +0300
+Subject: [PATCH] fix uselocale((locale_t)0) to not modify locale
+
+commit 68630b55c0c7 made the new locale to be assigned unconditonally
+resulting in crashes later on.
+---
+ src/locale/uselocale.c | 4 +---
+ 1 file changed, 1 insertion(+), 3 deletions(-)
+
+diff --git a/src/locale/uselocale.c b/src/locale/uselocale.c
+index b70a0c1..0fc5ecb 100644
+--- a/src/locale/uselocale.c
++++ b/src/locale/uselocale.c
+@@ -8,9 +8,7 @@ locale_t __uselocale(locale_t new)
+ locale_t old = self->locale;
+ locale_t global = &libc.global_locale;
+
+- if (new == LC_GLOBAL_LOCALE) new = global;
+-
+- self->locale = new;
++ if (new) self->locale = new == LC_GLOBAL_LOCALE ? global : new;
+
+ return old == global ? LC_GLOBAL_LOCALE : old;
+ }
+--
+2.4.2
+
diff --git a/main/musl/APKBUILD b/main/musl/APKBUILD
index 3567c306d5..a273267d3a 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.10
-pkgrel=0
+pkgrel=1
pkgdesc="the musl c library (libc) implementation"
url="http://www.musl-libc.org/"
arch="all"
@@ -12,6 +12,7 @@ depends_dev="!uclibc-dev"
makedepends="$depends_dev"
subpackages="$pkgname-dev $pkgname-utils $pkgname-dbg libc6-compat:compat"
source="http://www.musl-libc.org/releases/musl-$pkgver.tar.gz
+ 0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch
ldconfig
__stack_chk_fail_local.c
@@ -129,18 +130,21 @@ compat() {
}
md5sums="fc30892ee582c91920505bbd0021049f musl-1.1.10.tar.gz
+787a1c3661a0fcf887ec0d3c4550e90b 0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch
830d01f7821b978df770b06db3790921 ldconfig
0df687757221bbb0fc1aa67f1bd646f9 __stack_chk_fail_local.c
57ef2c63b9ec6a2041694ace97d4ffa2 getconf.c
2b941c4251cac44988a4abfc50e21267 getent.c
45f92f8d59cf84d765de698a9578dbf4 iconv.c"
sha256sums="45bbe9b1c7f7a0f743477af1e103b6889bfe4dd9815e16f6c89f6c90831c8b7c musl-1.1.10.tar.gz
+af5821fd50ad1587a9ef8117dc1e121cdda573f623286c6af4793e999afe840f 0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch
b4a2c06db38742e8c42c3c9838b285a7d8cdac6c091ff3df5ff9a15f1e41b9c7 ldconfig
299a7d75a09de3e2e11e7fb4acc3182e4a14e868093d2f30938fce9bfcff13da __stack_chk_fail_local.c
d87d0cbb3690ae2c5d8cc218349fd8278b93855dd625deaf7ae50e320aad247c getconf.c
68373a55e89ce85c562d941ccf588337d6cc6c9c17689d695f65cd7607134bbe getent.c
f79a2930a2e5bb0624321589edf8b889d1e9b603e01e6b7ae214616605b3fdd7 iconv.c"
sha512sums="183a66a8cc9cd056a8387a1602dd44b502d8976642a21dd0dcef51165fa0dec8a4a124fda6c1918f402b20ad2d6037fcc188a8b174b07a0cbedf11fc2e011141 musl-1.1.10.tar.gz
+a77981c637a091e19435ee8b3ef3ee21dbc7171f8fa88b59cfd42934a270bb92c9c3777c176fa64c814cd531244764f440f46fce532c4192d9727baa144b98e6 0001-fix-uselocale-locale_t-0-to-not-modify-locale.patch
8d3a2d5315fc56fee7da9abb8b89bb38c6046c33d154c10d168fb35bfde6b0cf9f13042a3bceee34daf091bc409d699223735dcf19f382eeee1f6be34154f26f ldconfig
062bb49fa54839010acd4af113e20f7263dde1c8a2ca359b5fb2661ef9ed9d84a0f7c3bc10c25dcfa10bb3c5a4874588dff636ac43d5dbb3d748d75400756d0b __stack_chk_fail_local.c
0d80f37b34a35e3d14b012257c50862dfeb9d2c81139ea2dfa101d981d093b009b9fa450ba27a708ac59377a48626971dfc58e20a3799084a65777a0c32cbc7d getconf.c