This commit is contained in:
Kelvin Sherlock 2012-05-12 01:25:36 -04:00
parent 5048a815ea
commit 046bbd6a16
3 changed files with 4 additions and 4 deletions

View File

@ -26,8 +26,6 @@ typedef struct Entry {
Word command;
LongWord cookie;
LongWord timeout;
Word socket_type;
// select magic.
selwakeupfx select_fx;
@ -54,6 +52,8 @@ typedef struct Entry {
unsigned _LINGER:1;
unsigned _NOSIGPIPE:1;
Word _TYPE;
LongWord _SNDLOWAT;
LongWord _RCVLOWAT;
LongWord _RCVTIMEO;

View File

@ -44,7 +44,7 @@ int mattach(int type, void *p1, void *p2, void *p3, void *p4, void *p5)
return ENOMEM;
}
e->select_fx = fx;
e->socket_type = type;
e->_TYPE = type;
*(Word *)p1 = ipid;

View File

@ -84,7 +84,7 @@ int mgetsockopt(Entry *e, void *p1, void *p2, void *p3, void *p4, void *p5)
case SO_TYPE:
// todo... non-stream
return set_flag(optval, optlen, SOCK_STREAM);
return set_flag(optval, optlen, e->_TYPE);
break;
case SO_DEBUG: