Skip site navigation (1) Skip section navigation (2)

Re: Win32 Error descriptions + config

From: "Magnus Naeslund(f)" <mag(at)fbab(dot)net>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-patches(at)postgresql(dot)org>
Subject: Re: Win32 Error descriptions + config
Date: 2002-04-15 05:15:02
Message-ID: 035901c1e43c$7f6b6580$020a0a0a@mnd (view raw, whole thread or download thread mbox)
Lists: pgsql-patches
From: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
> "Magnus Naeslund(f)" <mag(at)fbab(dot)net> writes:
> > The DLL load thingy doesn't work on all win9x machines, so i made it go thru a lookup table instead, using the DLL as last resort. 
> Is Windows really so lame that this information is not available from
> the system?  I do not like having to maintain our own error-message
> list.
> regards, tom lane

Sorry to say, yes.
The thing here is that if you build it on Win2k (as we do with our app(s)) and all is fine there, it will not work on win9x, returning a "Unknown socket error (0xNUMBER)" message (with our old code) because the DLL thing fails, and that's MUCH worse.
My rationale here is: This list is up-to-date with nt4 and if m$ add anything after that (win2k, XP) the DLL load thing will catch that.
It's a minor optimization even to just linearly scan the LUT compared to load a DLL (yeah i know it doesn't matter :)).

It's very common in the Microsoft world that they mess up the first releases of a API, and the after makes it "right", but then it's too late.
Often you can check the version of the kernel/system but not in this case.
I've looked around quite a lot, and would be a darn happy penguin if anyone could prove me wrong.


Magnus Naeslund

 Programmer/Networker [|] Magnus Naeslund

In response to


pgsql-patches by date

Next:From: Joe ConwayDate: 2002-04-15 05:18:13
Subject: Re: contrib/dblink update
Previous:From: Michael LoftisDate: 2002-04-15 05:12:36
Subject: Re: ANSI Compliant Inserts

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group