flua: fbsd: allow stdout to be captured for exec() processes
This allows us to do things like:
local fp = assert(fbsd.exec({"ls", "-l"}, true)) local fpout = assert(fp:stdout()) while true do local line = fpout:read("l") if not line then break end print("Read: " .. line) end fp:close()
The makeman lua rewrite will use it to capture make showconfig output
for processing.
Reviewed by: bapt
Differential Revision: https://reviews.freebsd.org/D50539
(cherry picked from commit 3f0e1092097ed63b83a02518395e370c3cac01be)