]> arthur.barton.de Git - ngircd-alex.git/blobdiff - src/ngircd/irc.c
Enhace connection statistics counters
[ngircd-alex.git] / src / ngircd / irc.c
index a0dc0ea9b8ed2b3722b736af9cf80575eab85627..67ad2a633a16747f49511154f205e47204263e45 100644 (file)
@@ -53,8 +53,12 @@ IRC_ERROR( CLIENT *Client, REQUEST *Req )
        assert( Client != NULL );
        assert( Req != NULL );
 
-       if( Req->argc < 1 ) Log( LOG_NOTICE, "Got ERROR from \"%s\"!", Client_Mask( Client ));
-       else Log( LOG_NOTICE, "Got ERROR from \"%s\": %s!", Client_Mask( Client ), Req->argv[0] );
+       if (Req->argc < 1)
+               Log(LOG_NOTICE, "Got ERROR from \"%s\"!",
+                   Client_Mask(Client));
+       else
+               Log(LOG_NOTICE, "Got ERROR from \"%s\": \"%s\"!",
+                   Client_Mask(Client), Req->argv[0]);
 
        return CONNECTED;
 } /* IRC_ERROR */
@@ -516,7 +520,7 @@ Send_Message_Mask(CLIENT * from, char * command, char * targetMask,
         * RFC 2812, sec. 3.3.1 requires that targetMask have at least one
         * dot (".") and no wildcards ("*", "?") following the last one.
         */
-       check_wildcards = strchr(targetMask, '.');
+       check_wildcards = strrchr(targetMask, '.');
        assert(check_wildcards != NULL);
        if (check_wildcards &&
                check_wildcards[strcspn(check_wildcards, "*?")])