166 |
|
client_dopacket(client_p, readBuf, dolen); |
167 |
|
} |
168 |
|
} |
169 |
< |
else if(IsClient(client_p)) |
169 |
> |
else if (IsClient(client_p)) |
170 |
|
{ |
171 |
|
if (ConfigFileEntry.no_oper_flood && (IsOper(client_p) || IsCanFlood(client_p))) |
172 |
|
{ |
390 |
|
} |
391 |
|
|
392 |
|
/* |
393 |
+ |
* iorecv_default - append a packet to the recvq dbuf |
394 |
+ |
*/ |
395 |
+ |
void * |
396 |
+ |
iorecv_default(va_list args) |
397 |
+ |
{ |
398 |
+ |
struct Client *client_p = va_arg(args, struct Client *); |
399 |
+ |
int length = va_arg(args, int); |
400 |
+ |
char *buf = va_arg(args, char *); |
401 |
+ |
|
402 |
+ |
dbuf_put(&client_p->localClient->buf_recvq, buf, length); |
403 |
+ |
return NULL; |
404 |
+ |
} |
405 |
+ |
|
406 |
+ |
/* |
407 |
|
* read_packet - Read a 'packet' of data from a connection and process it. |
408 |
|
*/ |
409 |
|
void |
440 |
|
errno = EWOULDBLOCK; |
441 |
|
case SSL_ERROR_SYSCALL: |
442 |
|
break; |
443 |
+ |
case SSL_ERROR_SSL: |
444 |
+ |
if (errno == EAGAIN) |
445 |
+ |
break; |
446 |
|
default: |
447 |
|
length = errno = 0; |
448 |
|
} |
451 |
|
#endif |
452 |
|
{ |
453 |
|
length = recv(fd->fd, readBuf, READBUF_SIZE, 0); |
437 |
– |
#ifdef _WIN32 |
438 |
– |
if (length < 0) |
439 |
– |
errno = WSAGetLastError(); |
440 |
– |
#endif |
454 |
|
} |
455 |
|
|
456 |
|
if (length <= 0) |
474 |
|
client_p->since = CurrentTime; |
475 |
|
ClearPingSent(client_p); |
476 |
|
|
464 |
– |
dbuf_put(&client_p->localClient->buf_recvq, readBuf, length); |
465 |
– |
|
477 |
|
/* Attempt to parse what we have */ |
478 |
|
parse_client_queued(client_p); |
479 |
|
|