Skip to content

Commit 4c0017c

Browse files
authored
Merge pull request #75 from ValwareIRC/patch-14
Elmer security update
2 parents 8930fdc + 69b5f64 commit 4c0017c

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

files/elmer.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ module
3131

3232
ModuleHeader MOD_HEADER = {
3333
"third/elmer",
34-
"2.1",
34+
"2.2",
3535
"Make people talk like Elmer",
3636
"Valware",
3737
"unrealircd-6",
@@ -100,6 +100,7 @@ MOD_INIT() {
100100
mreq.serialize = elmer_serialize;
101101
mreq.unserialize = elmer_unserialize;
102102
mreq.sync = 1;
103+
mreq.remote_write = 1;
103104
mreq.type = MODDATATYPE_CLIENT;
104105
elmer_md = ModDataAdd(modinfo->handle, mreq);
105106
if (!elmer_md)
@@ -195,7 +196,7 @@ CMD_FUNC(ADDELMER)
195196
if (!operclient && client == target) // client is not oper but wants to elmer themselves
196197
self++;
197198

198-
else if (!operclient)
199+
if (!operclient && !self)
199200
{
200201
sendnumeric(client, ERR_NOPRIVILEGES);
201202
return;
@@ -246,7 +247,7 @@ CMD_FUNC(DELELMER)
246247
if (!operclient && client == target) // client is not oper but wants to delmer themselves
247248
self++;
248249

249-
else if (!operclient)
250+
if (!operclient && !self)
250251
{
251252
sendnumeric(client, ERR_NOPRIVILEGES);
252253
return;

0 commit comments

Comments
 (0)