1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-03 07:33:13 +02:00

+ and dynconf, chrestrict

This commit is contained in:
stskeeps
2000-08-19 14:28:23 +00:00
parent cd277778a3
commit fe95cb9a1f
3 changed files with 21 additions and 4 deletions
+2
View File
@@ -562,3 +562,5 @@
it encrypts X and N lines too.
- Fixed empty mode sends in register_user, reported by Bagge
- Added some portability stuff
- Fixed some empty-line/missing parameter stuff in dccdeny, vhost,
and dynconf, chrestrict
+13 -3
View File
@@ -118,7 +118,8 @@ int load_conf(char *filename, int type)
iCstrip(buf);
version = strtok(buf, "^");
version = strtok(NULL, "");
if (!version)
goto malformed;
/* is this a unrealircd.conf file? */
if (!match("1.*", version))
{
@@ -189,6 +190,7 @@ int load_conf(char *filename, int type)
}
else
{
malformed:
if (type == 1)
{
sendto_ops
@@ -255,8 +257,12 @@ int load_conf2(FILE * conf, char *filename, int type)
if (*var == '\0')
continue;
strtok(NULL, " ");
setto = strtok(NULL, " ");
if (!setto)
continue;
setto = strtok(NULL, "");
if (!setto)
continue;
/* Is it a aint variable */
if (strcmp(var, "MODE_X") == 0)
{
@@ -428,8 +434,12 @@ int load_conf3(FILE * conf, char *filename, int type)
if (*var == '\0')
continue;
strtok(NULL, " ");
setto = strtok(NULL, " ");
if (!setto)
continue;
setto = strtok(NULL, "");
if (!setto)
continue;
/* Is it a aint variable */
if (strcmp(var, "iNAH") == 0)
{
+6 -1
View File
@@ -271,6 +271,8 @@ int dcc_loadconf(void)
if (buf[0] == '#' || buf[0] == '/' || buf[0] == '\0')
continue;
iCstrip(buf);
if (buf[0] == '#' || buf[0] == '/' || buf[0] == '\0')
continue;
x = strtok(buf, " ");
if (strcmp("deny", x) == 0)
{
@@ -526,6 +528,8 @@ int cr_loadconf(void)
if (buf[0] == '#' || buf[0] == '/' || buf[0] == '\0')
continue;
iCstrip(buf);
if (buf[0] == '#' || buf[0] == '/' || buf[0] == '\0')
continue;
x = strtok(buf, " ");
if (strcmp("allow", x) == 0)
{
@@ -668,9 +672,10 @@ int vhost_loadconf(void)
while (fgets(buf, 2048, f))
{
if (buf[0] == '#' || buf[0] == '/' || buf[0] == '\0')
continue;
iCstrip(buf);
if (buf[0] == '#' || buf[0] == '/' || buf[0] == '\0')
continue;
x = strtok(buf, " ");
if (strcmp("vhost", x) == 0)
{