Re: statistics process shutting down - Mailing list pgsql-hackers-win32

From Tom Lane
Subject Re: statistics process shutting down
Date
Msg-id 24231.1101847504@sss.pgh.pa.us
Whole thread Raw
In response to Re: statistics process shutting down  ("Merlin Moncure" <merlin.moncure@rcsonline.com>)
List pgsql-hackers-win32
"Merlin Moncure" <merlin.moncure@rcsonline.com> writes:
> if (ret < 0)
> {
>    int  wsa_errno;
>    wsa_errno = WSAGetLastError();

>    if (WSAECONNRESET == wsa_errno)
>    {   /* EOF on the pipe! (win32 socket based implementation) */
>       ret = 0;
>    }
>    else
>    {
>       errno = wsa_errno;  /* this *might* be ok */
>    }
> }

> Maybe Magnus might comment here.  This doesn't explain why the read call
> is failing but I'm pretty sure the error code is not being properly
> returned.

I recall a lot of angst about whether the encoding of WSAGetLastError()
is compatible with errno values, but I forget what the conclusion was.
Can we just assign to errno like that, or do we need a mapping function?

            regards, tom lane

pgsql-hackers-win32 by date:

Previous
From: "Merlin Moncure"
Date:
Subject: Re: statistics process shutting down
Next
From: "Merlin Moncure"
Date:
Subject: Re: statistics process shutting down