Re: libpq WSACleanup is not needed

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Andrew Chernow <ac(at)esilo(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: libpq WSACleanup is not needed
Date: 2009-01-16 15:17:18
Message-ID: 4970A4FE.709@hagander.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Alvaro Herrera <alvherre(at)commandprompt(dot)com> writes:
>> Magnus Hagander wrote:
>>> If you want to override this behavior today, you can just call
>>> WSAStartup() in your application, and it should never happen. Right?
>
>> Or perhaps use _init() and _fini() or the Win32 equivalents?
>
> I thought we were already relying on DLL load/unload-time calls
> in the Win32 port? Or maybe that was a long time ago and we got
> rid of it? I agree with Andrew that that would be a saner place
> for this than connection start.

We had it, and we removed it because the Win32 API docs say you're not
allowed to do it that way because of deadlock risks.

//Magnus

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Gregory Stark 2009-01-16 15:52:22 Re: FWD: Re: Updated backslash consistency patch
Previous Message Tom Lane 2009-01-16 15:15:40 Re: libpq WSACleanup is not needed