If you stay in this business long enough, you see a bit of everything. Notice the water heater’s T&P valve in the above photograph. The T&P valve discharges vertically up. What’s wrong with that?
There are many specific code requirements (13 to be exact) for the discharge piping from water heater T&P valves (Ref: 2012 International Plumbing Code 504.6). This installation violates requirements 8 and 9, which are:
8. Not be trapped.
9. Be installed so as to flow by gravity.
Obviously, with this incorrect installation, the discharge cannot flow by gravity. Also, water can fill and remain in the discharge pipe. Over time, stagnant water that remains in the discharge pipe can corrode the pipe and cause it to fail.
This is just a reminder. During field inspections, check the discharge pipe to verify code compliance.