If you are transferring it to a non relative I believe you have to go through an FFL. If it's a hand me down like from your father or something, I believe you can just take possession. At least that is the way it used to be. I haven't dealt with buying handguns in a private sale very often so I may not be 100% correct. And again, this is PA law only!
Close family, parents and siblings. The idea is that you know the person well and would know if they have a felony.
Otherwise you go to a ffl holder and do the paper work just like if you were buying it from the dealer.