[vfs/Pipe] - fix premature close of pipe. It should only be closed if
refcount is zero
Merge pull request #5741 from Memphiz/fixpipes

[vfs/Pipe] - fix premature close of pipe. It should only be closed if