Change awful.spawn for io.popen for performance improvment