+ /* Ein lokaler User. Alle andere Server informieren! */
+ Log( LOG_NOTICE, "User \"%s\" unregistered (connection %d): %s", Client_Mask( c ), c->conn_id, txt );
+
+ if( FwdMsg ) IRC_WriteStrServersPrefix( NULL, c, "QUIT :%s", FwdMsg );
+ else IRC_WriteStrServersPrefix( NULL, c, "QUIT :" );
+ }
+ else
+ {
+ /* Remote User. Andere Server informieren, ausser denen,
+ * die "in Richtung dem liegen", auf dem der User registriert
+ * ist. Von denen haben wir das QUIT ja wohl bekommen. */
+ Log( LOG_DEBUG, "User \"%s\" unregistered: %s", Client_Mask( c ), txt );
+
+ if( FwdMsg ) IRC_WriteStrServersPrefix( Client_NextHop( c ), c, "QUIT :%s", FwdMsg );
+ else IRC_WriteStrServersPrefix( Client_NextHop( c ), c, "QUIT :" );
+ }
+ Channel_RemoveClient( c, FwdMsg ? FwdMsg : c->id );
+ }
+ else if( c->type == CLIENT_SERVER )
+ {
+ if( c != This_Server )
+ {
+ if( c->conn_id != NONE ) Log( LOG_NOTICE, "Server \"%s\" unregistered (connection %d): %s", c->id, c->conn_id, txt );
+ else Log( LOG_NOTICE, "Server \"%s\" unregistered: %s", c->id, txt );
+ }
+
+ /* andere Server informieren */
+ if( ! NGIRCd_Quit )
+ {
+ if( FwdMsg ) IRC_WriteStrServersPrefix( Client_NextHop( c ), c, "SQUIT %s :%s", c->id, FwdMsg );
+ else IRC_WriteStrServersPrefix( Client_NextHop( c ), c, "SQUIT %s :", c->id );
+ }
+ }
+ else
+ {
+ if( c->conn_id != NONE )
+ {
+ if( c->id[0] ) Log( LOG_NOTICE, "Client \"%s\" unregistered (connection %d): %s", c->id, c->conn_id, txt );
+ else Log( LOG_NOTICE, "Client unregistered (connection %d): %s", c->conn_id, txt );
+ }
+ else
+ {
+ if( c->id[0] ) Log( LOG_WARNING, "Unregistered unknown client \"%s\": %s", c->id, txt );
+ else Log( LOG_WARNING, "Unregistered unknown client: %s", c->id, txt );