I can't tell from the pic, but make sure there is enough length of pipe to fully seat the vertical straight pipe into the fitting.
If not, simply cut it in the middle, add a Fernco hubless (rubber) fitting to join the cut sections of pipe.
It's possible your tank, floor, whatever has sagged a bit and pulled the joint apart, or it may have been cut too short when mfg.
I don't remember the size of the pipe (make sure you check), but here is a similar fitting at Home Depot.
http://www.homedepot.com/p/Fernco-1-1-4-in-x-1-1-4-in-Flexible-PVC-Coupling-P1056-125/100055392#.Udn18W2GnDc
If your tank or straps or whatever are flexing, this will help prevent another failure, too.