* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
* USA
*
- * $Id: s_serv.c 3354 2007-04-03 09:21:31Z nenolod $
+ * $Id: s_serv.c 3550 2007-08-09 06:47:26Z nenolod $
*/
#include "stdinc.h"
#include "channel.h" /* chcap_usage_counts stuff... */
#include "hook.h"
#include "msg.h"
+#include "reject.h"
extern char *crypt();
target_p->name, target_p->hopcount + 1,
(long) target_p->tsinfo, ubuf,
target_p->username, target_p->host,
- target_p->user->server, target_p->info);
+ target_p->servptr->name, target_p->info);
if(IsDynSpoof(target_p))
sendto_one(client_p, ":%s ENCAP * REALHOST %s",
(long) target_p->tsinfo,
ubuf,
target_p->username, target_p->host,
- target_p->user->server, target_p->info);
+ target_p->servptr->name, target_p->info);
if(!has_id(target_p) || !IsCapable(client_p, CAP_EUID))
{
*/
if(!EmptyString(server_p->spasswd))
{
- /* kludge, if we're not using TS6, dont ever send
- * ourselves as being TS6 capable.
- */
- if(ServerInfo.use_ts6)
- sendto_one(client_p, "PASS %s TS %d :%s",
- server_p->spasswd, TS_CURRENT, me.id);
- else
- sendto_one(client_p, "PASS %s :TS",
- server_p->spasswd);
+ sendto_one(client_p, "PASS %s TS %d :%s",
+ server_p->spasswd, TS_CURRENT, me.id);
}
/* pass info to new server */
set_chcap_usage_counts(client_p);
dlinkAdd(client_p, &client_p->lnode, &me.serv->servers);
+ del_unknown_ip(client_p);
dlinkMoveNode(&client_p->localClient->tnode, &unknown_list, &serv_list);
dlinkAddTailAlloc(client_p, &global_serv_list);
client_p->localClient->firsttime = CurrentTime;
/* fixing eob timings.. -gnp */
+ if((dlink_list_length(&lclient_list) + dlink_list_length(&serv_list)) >
+ (unsigned long)MaxConnectionCount)
+ MaxConnectionCount = dlink_list_length(&lclient_list) +
+ dlink_list_length(&serv_list);
+
/* Show the real host/IP to admins */
sendto_realops_snomask(SNO_GENERAL, L_ALL,
"Link with %s established: (%s) link",
*/
if(!EmptyString(server_p->spasswd))
{
- if(ServerInfo.use_ts6)
- sendto_one(client_p, "PASS %s TS %d :%s",
- server_p->spasswd, TS_CURRENT, me.id);
- else
- sendto_one(client_p, "PASS %s :TS",
- server_p->spasswd);
+ sendto_one(client_p, "PASS %s TS %d :%s",
+ server_p->spasswd, TS_CURRENT, me.id);
}
/* pass my info to the new server */