Skip to content

Cope better with non-ASCII library names

Simon McVittie requested to merge wip/sr385-non-ascii into master
  • inspect-library: Add a line-based octal output format

    Instead of trying to format JSON using only glibc, this just prints key=value lines, some of which can be repeated. The values always have control characters and backslashes escaped as C-style octal sequences such as \040 for space, similar to the encoding of /etc/fstab. This allows non-UTF-8 bytestrings to be represented.

  • library: Use line-based output from inspect-library

    This means we can cope with filenames in their filesystem encoding, which are arbitrary bytestrings (not necessarily UTF-8).

  • system-info: Cope with non-UTF-8 library paths

    JSON strings must be valid Unicode, so use the lossy transformation in g_utf8_make_valid() to replace non-UTF-8 (if found) with U+FFFD REPLACEMENT CHARACTER.

  • system-info: Force environment variables into UTF-8

Merge request reports