Check-in Number:
|
1483 | |
Date: |
2002-Jan-02 14:27:11 (local)
2002-Jan-02 13:27:11 (UTC) |
User: | rse |
Branch: | |
Comment: |
complain if no socket is available for SA_OPTION_NONBLOCK |
Tickets: |
|
Inspections: |
|
Files: |
|
ossp-pkg/sa/sa.c 1.46 -> 1.47
--- sa.c 2002/01/02 13:21:07 1.46
+++ sa.c 2002/01/02 13:27:11 1.47
@@ -1147,6 +1147,10 @@
/* enable/disable non-blocking I/O mode */
int flags;
int mode = (int)va_arg(ap, int);
+ if (sa->fdSocket == -1) {
+ rv = SA_ERR_USE;
+ break;
+ }
if ((flags = fcntl(sa->fdSocket, F_GETFL, 0)) < 0) {
rv = SA_ERR_SYS;
break;
|
|