Revert "postgresql: remove unneeded patch since b9c230dd"

Ooops, sorry. I didn't see the exact content of the patch.

This reverts commit ce41e7e2a7ccb73325f3b037f47b9d213594fb4d.