diff options
author | Timo Teräs <timo.teras@iki.fi> | 2015-04-13 09:40:36 +0300 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2015-04-13 09:42:27 +0300 |
commit | 43955329325c823579ded743efb324cc8ea1daba (patch) | |
tree | 4045296c7f684325860d83e4d9b91419e495d604 /src/url.c | |
parent | 2322ba0ad938c142d0bb7a715940fc75ccdbe91b (diff) | |
download | apk-tools-43955329325c823579ded743efb324cc8ea1daba.tar.gz apk-tools-43955329325c823579ded743efb324cc8ea1daba.tar.bz2 apk-tools-43955329325c823579ded743efb324cc8ea1daba.tar.xz apk-tools-43955329325c823579ded743efb324cc8ea1daba.zip |
fix error mapping types
on arm char is by default unsigned, so this caused crashes
as the ERR_PTR mechanism did not work as expected with unsigned
types. extend the array type to be signed short explicitly.
Diffstat (limited to 'src/url.c')
-rw-r--r-- | src/url.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -40,7 +40,7 @@ struct apk_fetch_istream { static int fetch_maperror(int ec) { - static const char map[] = { + static const signed short map[] = { [FETCH_ABORT] = -ECONNABORTED, [FETCH_AUTH] = -EACCES, [FETCH_DOWN] = -ECONNREFUSED, |