Description

If you walk into a nether portal, you don't spawn at the right position in the nether and the other way around. You always spawn some blocks beside the portal and get suffocated if there is a wall.

To recreate the bug, i created a fresh world, built a nether portal and go through it. Then i got stuck in the netherrack some blocks under and beside the portal. But the portal was created just fine. When i wanted to go back to the overworld, i spawned 2 blocks in front of the portal in the overworld.

Adapted from Anomie X's comment:
On 1.8.3, the cause of this issue is located in the class named "adv", which handles portal travel:
In the code for placing the player there's a bit like this, which seems to be for adjusting the X/Z position from the corner portal-block of the destination portal to more closely match where the entity entered the source portal. var31 is X, var33 is Z.

The lines I've commented with "!!!" are the problem, they move the entity 1 block in the "facing" direction of the portal without bothering to check for ground underneath, blocks in the way, or anything else. Modding the class to remove those two lines restores the expected behavior of spawning within the destination portal itself.

MC-74607A bug when you go through nether portals it spawns you in the side. This can be bad because you can get stuck in a wall and suffocate or, like what happened to myself, you can fall off the edge when going to the nether.