I ran into an SSL issue when using the MSYS2/MINGW build of Postgres for the PgBouncer test suite. Postgres crashed whenever you tried to open an ssl connection to it. https://github.com/msys2/MINGW-packages/issues/19851
I'm wondering if the issue described in this thread could be related to the issue I ran into. Afaict the merged patch has not been released yet.