X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fngircd%2Fconn.c;h=4a028ac7794b0fc7eeb9be7c825c0d94e506ff97;hb=c2e4c304e3adde2217056c2e6d674fd24e0cd800;hp=daf496b4186a58d3f43ba8c22339918a318e05e1;hpb=d118cd74b6ff342b978b493d56f9306028e364cf;p=ngircd-alex.git diff --git a/src/ngircd/conn.c b/src/ngircd/conn.c index daf496b4..4a028ac7 100644 --- a/src/ngircd/conn.c +++ b/src/ngircd/conn.c @@ -328,7 +328,7 @@ Conn_Init( void ) array_bytes(&My_ConnArray)); assert(array_length(&My_ConnArray, sizeof(CONNECTION)) >= (size_t)Pool_Size); - + array_free( &My_Listeners ); for (i = 0; i < Pool_Size; i++) @@ -796,7 +796,7 @@ Conn_Handler(void) GLOBAL bool Conn_WriteStr(CONN_ID Idx, const char *Format, ...) #else -GLOBAL bool +GLOBAL bool Conn_WriteStr(Idx, Format, va_alist) CONN_ID Idx; const char *Format; @@ -829,7 +829,7 @@ va_dcl * IRC_WriteXXX() functions when the prefix of this server had * to be added to an already "quite long" command line which * has been received from a regular IRC client, for example. - * + * * We are not allowed to send such "oversized" messages to * other servers and clients, see RFC 2812 2.3 and 2813 3.3 * ("these messages SHALL NOT exceed 512 characters in length, @@ -1487,7 +1487,7 @@ Conn_StartLogin(CONN_ID Idx) ident_sock = My_Connections[Idx].sock; #endif - if (Conf_NoticeAuth) { + if (Conf_NoticeBeforeRegistration) { /* Send "NOTICE *" messages to the client */ #ifdef IDENTAUTH if (Conf_Ident) @@ -1583,7 +1583,7 @@ Read_Request( CONN_ID Idx ) if (len == 0) { LogDebug("Client \"%s:%u\" is closing connection %d ...", My_Connections[Idx].host, - ng_ipaddr_tostr(&My_Connections[Idx].addr), Idx); + ng_ipaddr_getport(&My_Connections[Idx].addr), Idx); Conn_Close(Idx, NULL, "Client closed connection", false); return; } @@ -2265,7 +2265,7 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events ) strlcpy(My_Connections[i].host, readbuf, sizeof(My_Connections[i].host)); Client_SetHostname(c, readbuf); - if (Conf_NoticeAuth) + if (Conf_NoticeBeforeRegistration) (void)Conn_WriteStr(i, "NOTICE * :*** Found your hostname: %s", My_Connections[i].host); @@ -2291,7 +2291,7 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events ) i, identptr); Client_SetUser(c, identptr, true); } - if (Conf_NoticeAuth) { + if (Conf_NoticeBeforeRegistration) { (void)Conn_WriteStr(i, "NOTICE * :*** Got %sident response%s%s", *ptr ? "invalid " : "", @@ -2300,13 +2300,13 @@ cb_Read_Resolver_Result( int r_fd, UNUSED short events ) } } else if(Conf_Ident) { Log(LOG_INFO, "IDENT lookup for connection %d: no result.", i); - if (Conf_NoticeAuth) + if (Conf_NoticeBeforeRegistration) (void)Conn_WriteStr(i, "NOTICE * :*** No ident response"); } #endif - if (Conf_NoticeAuth) { + if (Conf_NoticeBeforeRegistration) { /* Send buffered data to the client, but break on * errors because Handle_Write() would have closed * the connection again in this case! */ @@ -2364,7 +2364,7 @@ Simple_Message(int Sock, const char *Msg) * @returns Pointer to CLIENT structure. */ GLOBAL CLIENT * -Conn_GetClient( CONN_ID Idx ) +Conn_GetClient( CONN_ID Idx ) { CONNECTION *c;