mpv-player/mpv — pull request #1093 by rossy2401 (2014-09-14 16:17:22+00:00)
Title: Don't free NULL libwaio pointer

It seems waio_alloc can fail when the input handle is a console. waio_free crashes if given a NULL pointer, so check for NULL before freeing.