Everything was normal when i was staying close to a zombie pigman at the begining. Once I hit one, they became hostile as expected, but they never get back to neutral no matter what difficulty.
I tried:
1. Let them kill me. Still hostile after death;
2. Put difficulty on peacefull, Still hostile;
3. Restart game / computer;
4. verify Java update;
5. Use invisibility potions and remove everything on me, still see me and hostile.
Can't reproduce. When you switch your game to peaceful all hostile mobs including zombie pigmen should disappear. I tested and that is what happened to me as expected. Are you certain you changed your difficulty to peaceful?