Received: from candle.pha.pa.us (candle.navpoint.com [162.33.245.46]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f5A2mxE69671 for ; Sat, 9 Jun 2001 22:48:59 -0400 (EDT) (envelope-from pgman@candle.pha.pa.us) Received: (from pgman@localhost) by candle.pha.pa.us (8.10.1/8.10.1) id f5A2mcB21490; Sat, 9 Jun 2001 22:48:38 -0400 (EDT) From: Bruce Momjian Message-Id: <200106100248.f5A2mcB21490@candle.pha.pa.us> Subject: Re: [DOCS] Re: libpq sockets on win32 In-Reply-To: <81124B76C0CF364EBAC6CD213ABEDEF701AA0D@ARGON.edu.sollentuna.se> "from Magnus Hagander at Jun 5, 2001 04:47:02 pm" To: Magnus Hagander Date: Sat, 9 Jun 2001 22:48:38 -0400 (EDT) CC: jeff@jeffjohnson.net, pgsql-interfaces@postgresql.org X-Mailer: ELM [version 2.4ME+ PL90 (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Archive-Number: 200106/39 X-Sequence-Number: 1701 > > > I don't know enough about such things. > > > > The web page wasn't clear about that. > No, that list is not correct. > > 1) select() can *only* be used on a socket in Windows, and it puts its > error info in WSAGetLastError(). > > 2) ioctl() should *not* be used on sockets. Instead, ioctlsocket() > shuold be used. ioctlsocket() puts its error info in WSAGetLastError(). > (http://msdn.microsoft.com/library/psdk/winsock/ovrvw3_98mq.htm). (loads > fine in my Netscape, doesn't look all that good, but definitly readable) > > 3) fcntl() should *not* be used on sockets. ioctlsocket() again. > > Generaelly, all functions dealing with sockets use WSAGetLastError(). > And sockets and file descriptors are *not* necessarily interchangable on > Win32. > > > Note - this is Win32, *not* cygwin. Cygwin maps to errno, AFAIK. OK, I have heard enough to know that I don't want to try this patch without a WIN32 development environment, which I don't have. Seems like we have some major libpq work to do for WIN32. If someone wants to code something, we will consider applying it. Sorry. -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 853-3000 + If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania 19026