Maxscale doesn't assert if tested with different errors in gw_MySQLAccept.

This commit is contained in:
vraatikka
2013-09-24 16:09:11 +03:00
parent 09cc20b7be
commit 20c4a60f01

View File

@ -943,12 +943,13 @@ int gw_MySQLAccept(DCB *listener)
if (c_sock == -1) { if (c_sock == -1) {
if (eno == EAGAIN || if (eno == EAGAIN || eno == EWOULDBLOCK)
eno == EWOULDBLOCK)
{ {
/**
* We have processed all incoming connections.
*/
rc = 1; rc = 1;
/* We have processed all incoming connections. */ goto return_rc;
break;
} }
else if (eno == ENFILE || eno == EMFILE) else if (eno == ENFILE || eno == EMFILE)
{ {
@ -982,8 +983,8 @@ int gw_MySQLAccept(DCB *listener)
pthread_self(), pthread_self(),
eno, eno,
strerror(eno)); strerror(eno));
ss_dassert(false); rc = 1;
break; goto return_rc;
} /* if (eno == ..) */ } /* if (eno == ..) */
} /* if (c_sock == -1) */ } /* if (c_sock == -1) */
/* reset counter */ /* reset counter */
@ -1072,8 +1073,7 @@ int gw_MySQLAccept(DCB *listener)
#if defined(SS_DEBUG) #if defined(SS_DEBUG)
if (rc == 0) { if (rc == 0) {
CHK_DCB(client_dcb); CHK_DCB(client_dcb);
protocol = (MySQLProtocol *)client_dcb->protocol; CHK_PROTOCOL(((MySQLProtocol *)client_dcb->protocol));
CHK_PROTOCOL(protocol);
} }
#endif #endif
return_rc: return_rc: