Fixes bug in sys_pipe()