Permalink
Browse files

pick me

  • Loading branch information...
vanosg committed Oct 9, 2017
1 parent 6306685 commit 6d906d6f9124f3d4174bc128d3c1146fc0fdc927
Showing with 22 additions and 12 deletions.
  1. +22 −12 src/userent.c
View
@@ -680,26 +680,36 @@ static int botaddr_tcl_set(Tcl_Interp * irp, struct userrec *u,
nfree(bi->address);
bi->address = user_malloc(strlen(argv[3]) + 1);
strcpy(bi->address, argv[3]);
if (argc > 4)
if (argc > 4) {
#ifdef TLS
{
if (*argv[4] == '+')
if (*argv[4] == '+') {
bi->ssl |= TLS_BOT;
} else {
bi->ssl &= ~TLS_BOT;
}
if (argc == 5) {
if (*argv[4] == '+') {
bi->ssl |= TLS_RELAY;
} else {
bi->ssl &= ~TLS_RELAY;
}
}
#endif
bi->telnet_port = atoi(argv[4]);
if (argc == 5) {
bi->relay_port = atoi(argv[4]);
}
}
#else
bi->telnet_port = atoi(argv[4]);
#endif
if (argc > 5)
if (argc > 5) {
#ifdef TLS
{
if (*argv[5] == '+')
if (*argv[5] == '+') {
bi->ssl |= TLS_RELAY;
} else {
bi->ssl &= ~TLS_RELAY;
}
#endif
bi->relay_port = atoi(argv[5]);
}
#else
bi->relay_port = atoi(argv[5]);
#endif
if (!bi->telnet_port)
bi->telnet_port = 3333;
if (!bi->relay_port)

0 comments on commit 6d906d6

Please sign in to comment.