Revert "Revert "convert stdout's input to string,""

This reverts commit 1e3991f0f3e072629a0f9968799f7c68082925a1.