Fix an error blocking with os.read() at starting