mirror of https://github.com/mpv-player/mpv
cc54377463
...because everything is terrible. strerror() is not documented as having to be thread-safe by POSIX and C11. (Which is pretty much bullshit, because both mandate threads and some form of thread-local storage - so there's no excuse why implementation couldn't implement this in a thread-safe way. Especially with C11 this is ridiculous, because there is no way to use threads and convert error numbers to strings at the same time!) Since we heavily use threads now, we should avoid unsafe functions like strerror(). strerror_r() is in POSIX, but GNU/glibc deliberately fucks it up and gives the function different semantics than the POSIX one. It's a bit of work to convince this piece of shit to expose the POSIX standard function, and not the messed up GNU one. strerror_l() is also in POSIX, but only since the 2008 standard, and thus is not widespread. The solution is using avlibc (libavutil, by its official name), which handles the unportable details for us, mostly. We avoid some pain. |
||
---|---|---|
.. | ||
cmd_list.c | ||
cmd_list.h | ||
cmd_parse.c | ||
cmd_parse.h | ||
event.c | ||
event.h | ||
input.c | ||
input.h | ||
ipc.c | ||
joystick.c | ||
keycodes.c | ||
keycodes.h | ||
lirc.c | ||
pipe-win32.c |