| 38 |
|
#include "conf.h" |
| 39 |
|
|
| 40 |
|
|
| 41 |
< |
/*! \brief SVSMODE command handler (called by services) |
| 41 |
> |
/*! \brief SVSMODE command handler |
| 42 |
|
* |
| 43 |
|
* \param source_p Pointer to allocated Client struct from which the message |
| 44 |
|
* originally comes from. This can be a local or remote client. |
| 58 |
|
struct Client *target_p = NULL; |
| 59 |
|
int what = MODE_ADD; |
| 60 |
|
unsigned int flag = 0, setmodes = 0; |
| 61 |
< |
const char *m = NULL, *modes = NULL, *extarg = NULL; |
| 61 |
> |
const char *modes = NULL, *extarg = NULL; |
| 62 |
|
time_t ts = 0; |
| 63 |
|
|
| 64 |
|
if (!HasFlag(source_p, FLAGS_SERVICE)) |
| 84 |
|
|
| 85 |
|
setmodes = target_p->umodes; |
| 86 |
|
|
| 87 |
< |
for (m = modes; *m; ++m) |
| 87 |
> |
for (const char *m = modes; *m; ++m) |
| 88 |
|
{ |
| 89 |
|
switch (*m) |
| 90 |
|
{ |
| 169 |
|
|
| 170 |
|
if (MyConnect(target_p) && (setmodes != target_p->umodes)) |
| 171 |
|
{ |
| 172 |
< |
char modebuf[IRCD_BUFSIZE]; |
| 172 |
> |
char modebuf[IRCD_BUFSIZE] = ""; |
| 173 |
|
|
| 174 |
|
send_umode(target_p, target_p, setmodes, 0xffffffff, modebuf); |
| 175 |
|
} |