From: | Magnus Hagander <magnus(at)hagander(dot)net> |
---|---|
To: | Andrew Chernow <ac(at)esilo(dot)com> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-patches(at)postgresql(dot)org |
Subject: | Re: libpq Win32 Mutex performance patch |
Date: | 2008-04-21 11:51:10 |
Message-ID: | 20080421135110.1cde485c@mha-laptop |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
Andrew Chernow wrote:
> Tom Lane wrote:
> >Silently not locking is surely
> > not very safe.
> >
>
> Here is the dump code version of the patch. If anyone wants the
> return value idea, let me know.
Here's a version of this patch that doesn't use malloc - instead, I had
to change the callers to it a bit.
This makes a difference only on Vista+ really, because prior to Vista
the function InitializeCriticalSection() *can* fail - it will throw an
exception and not return any error code. Which really isn't that
different from just crashing like this latest patch from Andrew would
have us do (on out of memory).
I'm leaning towards going with the simpler one, which is the patch from
Andrew that crashes on out of memory.
Comments/preferences?
//Magnus
Attachment | Content-Type | Size |
---|---|---|
libpq.diff | text/x-patch | 3.5 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2008-04-21 15:19:03 | Re: Proposed patch - psql wraps at window width |
Previous Message | Magnus Hagander | 2008-04-21 08:31:12 | Re: Testing pg_terminate_backend() |