Fix wrong behaviour on early errors when creating socket stream.
Looks like sh does not like "set -o pipefail" on linux.