The pidof tests try to block a subprocess forever by reading from
stdout via /proc/self/fd/1. This works for most stdout fds, but
fails if stdout is a socket, which happens when running the tests
in a sandbox in the Android build. Create a named fifo and read
on that instead.
Before this patch, we're effectively doing `pidof -x` all the time. This
patch changes names_to_pid() to allow us to say whether or not we want to
include scripts, and adjusts the callers appropriately.
Also add tests for `pidof` versus `pidof -x` which pass after this
patch, without regressing the existing killall tests.