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

Enable additional compiler warnings. Update code to conform to these

new standards, possible to compile with -Werror with them.
This commit is contained in:
Bram Matthys
2019-03-27 09:03:30 +01:00
parent 5a38d8ed75
commit dd2af3b31c
14 changed files with 1765 additions and 658 deletions
+1 -1
View File
@@ -502,7 +502,7 @@ invalidsyntax:
return EX_DENY;
}
/* falltrough -- should not be used */
/* fallthrough -- should not be used */
return EX_DENY;
}
+1 -1
View File
@@ -107,7 +107,7 @@ int cmodeL_is_ok(aClient *sptr, aChannel *chptr, char mode, char *para, int type
return EX_ALLOW;
}
/* falltrough -- should not be used */
/* fallthrough -- should not be used */
return EX_DENY;
}
+1
View File
@@ -32,6 +32,7 @@ ModuleHeader MOD_HEADER(m_chghost)
"4.2", /* Version */
"/chghost", /* Short description of module */
"3.2-b8-1",
NULL
};
MOD_INIT(m_chghost)
+4 -1
View File
@@ -821,6 +821,7 @@ int do_mode_char(aChannel *chptr, long modetype, char modechar, char *param,
if (!is_halfop(cptr, chptr)) /* htrig will take care of halfop override notices */
opermode = 1;
}
goto process_listmode;
case MODE_CHANPROT:
REQUIRE_PARAMETER()
/* not uline, not server, not chanowner, not an samode, not -a'ing yourself... */
@@ -835,12 +836,13 @@ int do_mode_char(aChannel *chptr, long modetype, char modechar, char *param,
if (!is_halfop(cptr, chptr)) /* htrig will take care of halfop override notices */
opermode = 1;
}
goto process_listmode;
case MODE_HALFOP:
case MODE_CHANOP:
case MODE_VOICE:
REQUIRE_PARAMETER()
process_listmode:
if (!(who = find_chasing(cptr, param, &chasing)))
break;
if (!who->user)
@@ -1656,6 +1658,7 @@ CMD_FUNC(_m_umode)
set_snomask(sptr, parv[3]);
goto def;
}
break;
case 'o':
case 'O':
if(sptr->from->flags & FLAGS_QUARANTINE)
+1 -1
View File
@@ -3052,7 +3052,7 @@ static int comp_with_mask(void *addr, void *dest, u_int mask)
if (memcmp(addr, dest, mask / 8) == 0)
{
int n = mask / 8;
int m = ((-1) << (8 - (mask % 8)));
int m = (0xffff << (8 - (mask % 8)));
if (mask % 8 == 0 || (((u_char *) addr)[n] & m) == (((u_char *) dest)[n] & m))
{
return (1);
+1 -1
View File
@@ -474,7 +474,7 @@ int webirc_local_pass(aClient *sptr, char *password)
return dowebirc(sptr, ip, host, NULL);
}
/* falltrough if not in webirc block.. */
/* fallthrough if not in webirc block.. */
}
return 0; /* not webirc */