fixed forwarding of stdout from device