Fix Pipe copy/assignment to make a copy of flags.