Update pipe_r.cpp