Trace - This is a setup / shooting issue, not a PP one.
The issue that you are seeing is that your camera was not rotated around the lenses entrance pupil, with part of the scene in the foreground. That is why you are getting the "bowing" effect. I'm not sure what your setup looks like, but this is more or less what I use. Getting rid of the foreground would also solve your problem.
You might find the following link of use:
http://www.johnhpanos.com/epcalib.htm . It covers a lot of the material.
If you get the entrance pupil correct, and rotate around it, then you won't see the bowing. Example here is one of my panos; the railing is straight, so I can tell I got the entrance pupil distance right.
I hope that this helps.