glibc/iconv
Siddhesh Poyarekar 9429049c17 iconvconfig: Fix multiple issues
It was noticed on big-endian systems that msgfmt would fail with the
following error:

msgfmt: gconv_builtin.c:70: __gconv_get_builtin_trans: Assertion `cnt < sizeof (map) / sizeof (map[0])' failed.
Aborted (core dumped)

This is only seen on installed systems because it was due to a
corrupted gconv-modules.cache.  iconvconfig had the following issues
(it was specifically freeing fulldir that caused this issue, but other
cleanups are also needed) that this patch fixes.

- Add prefix only if dir starts with '/'
- Use asprintf instead of mempcpy so that the directory string is NULL
  terminated
- Make a copy of the directory reference in new_module so that fulldir
  can be freed within the same scope in handle_dir.

Reviewed-by: Florian Weimer <fweimer@redhat.com>
2021-06-28 09:15:55 +05:30
..
dummy-repertoire.c
gconv_builtin.c
gconv_builtin.h
gconv_cache.c Use 64 bit time_t stat internally 2021-06-22 12:09:52 -03:00
gconv_charset.c
gconv_charset.h
gconv_close.c
gconv_conf.c gconv_conf: Split out configuration file processing 2021-06-23 08:54:13 +05:30
gconv_db.c
gconv_dl.c
gconv_int.h
gconv_open.c
gconv_parseconfdir.h Handle DT_UNKNOWN in gconv-modules.d 2021-06-23 08:54:13 +05:30
gconv_simple.c
gconv_trans.c
gconv.c
gconv.h
iconv_charmap.c
iconv_close.c
iconv_open.c
iconv_prog.c
iconv_prog.h
iconv.c
iconv.h
iconvconfig.c iconvconfig: Fix multiple issues 2021-06-28 09:15:55 +05:30
iconvconfig.h
loop.c
Makefile iconvconfig: Fix multiple issues 2021-06-28 09:15:55 +05:30
skeleton.c
strtab.c
test-gconv-modules
tst-gconv-init-failure-mod.c
tst-gconv-init-failure.c
tst-iconv1.c
tst-iconv2.c
tst-iconv3.c
tst-iconv4.c
tst-iconv5.c
tst-iconv6.c
tst-iconv7.c
tst-iconv8.c
tst-iconv_prog.sh
tst-iconv-mt.c
tst-iconv-opt.c
Versions