2017-01-05 16:30:02 UTC
I've now tracked this down: libpthread apparently overrode
__errno_location to point it to td->errno, where td is POSIX
thread descriptor. This is just plain wrong, because errno is
now a (TLS) variable, while in ancient dietlibc versions it
used to be defined as the dereference of said function.
However, syscalls still use that function to set the errno,
so any code checking errno would fail in that case.
Once I've made sure #844781 is fixed (and no other problems
have arisen in the mean time), this will be part of the next