Subject: | |
From: | |
Reply To: | |
Date: | Wed, 27 Mar 2002 15:03:21 -0800 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
Jeff Woods wrote:
> Fatal DB Open Error :
> connectMakeNonblocking -- fcntl() failed: errno=9
> Bad file number
>
> I have the impression that fcntl() isn't supported with sockets on MPE and
> that these calls should be sfcntl() instead. Is that correct? If so, I
> don't see how Pete's test above worked. [The next thing I'm going to try
> is changing that fcntl() to sfcntl() and rebuilding libpq.a on MPE to see
> if that helps.]
I thought I had dealt with this:
diff -ru postgresql-7.1.2/src/interfaces/libpq/fe-connect.c postgresql-7.1.2-mpe
/src/interfaces/libpq/fe-connect.c
--- postgresql-7.1.2/src/interfaces/libpq/fe-connect.c Sat Mar 31 15:14:37 2001
+++ postgresql-7.1.2-mpe/src/interfaces/libpq/fe-connect.c Tue Jun 19 20:56
:06 2001
@@ -705,6 +705,8 @@
int on = 1;
if (ioctl(conn->sock, FIONBIO, &on) != 0)
+#elif defined(mpeix)
+ if (sfcntl(conn->sock, F_SETFL, O_NONBLOCK) < 0)
#else
if (fcntl(conn->sock, F_SETFL, O_NONBLOCK) < 0)
#endif
Of course, it's possible I missed another fcntl that is dealing with sockets.
But since you have the source, feel free to fix it on my behalf. ;-)
--
[log in to unmask]
Remainder of .sig suppressed to conserve expensive California electrons...
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
|
|
|