Re: WIN32 errno patch

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Bruce Momjian - CVS <momjian(at)hub(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: WIN32 errno patch
Date: 2001-08-02 15:47:55
Message-ID: 200108021547.f72FltH27228@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers pgsql-patches


Any idea where we are on this?

> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> > At this point, I am just happy we have this WIN32 errno thing working.
>
> My point is that it isn't "working", it's broken.
>
> > My guess is that we should have two errno's. One the normal errno that
> > is the same on Win32 and Unix and a sockerrno that is conditionally
> > defined:
>
> I don't really want to uglify the code by replacing most of the "errno"
> uses with "sockerrno". People know what errno is, they don't know what
> "sockerrno" is, so we'd be reducing the readability of the code in order
> to cater to Windows cultural imperialism (usual M$ philosophy: embrace,
> extend, and make sure Windows-compatible code can't run anywhere else).
>
> Since there are only about three routines in libpq that need access to
> "regular" errno, it seems less invasive to #define errno for the rest
> of them, and do something special in just these places.
>
> regards, tom lane
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2001-08-02 15:59:29 pgsql/src/backend/commands trigger.c
Previous Message Bruce Momjian - CVS 2001-08-02 15:45:55 pgsql/ oc/src/sgml/pltcl.sgml rc/pl/tcl/pltcl.c

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2001-08-02 15:52:19 Name for new VACUUM
Previous Message Bruce Momjian 2001-08-02 15:46:36 Re: plpgsql: RAISE <level> <expr> <params>

Browse pgsql-patches by date

  From Date Subject
Next Message Tom Lane 2001-08-02 16:11:01 Re: WIN32 errno patch
Previous Message Bruce Momjian 2001-08-02 15:46:05 Re: [HACKERS] pltcl - lastoid