projects
/
srvx.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
9a7baf0
)
bugfixes and some polishing
author
NurPech
<nurpech@nurpech.de>
Mon, 7 Jan 2013 19:06:39 +0000
(20:06 +0100)
committer
NurPech
<nurpech@nurpech.de>
Mon, 7 Jan 2013 19:06:39 +0000
(20:06 +0100)
src/mod-hostserv.c
patch
|
blob
|
history
diff --git
a/src/mod-hostserv.c
b/src/mod-hostserv.c
index a2e50d30aa8ee1c860ae8d0d9b2215198a8361d5..82e9058b6112ae73365575cb0cb10b515044d5db 100644
(file)
--- a/
src/mod-hostserv.c
+++ b/
src/mod-hostserv.c
@@
-766,8
+766,8
@@
static MODCMD_FUNC(cmd_addhost) {
reply("HSMSG_FAKEHOST_TOPLEVEL_ALREADY_EXISTS", slfh_name, tlfh_name);
return 0;
}
reply("HSMSG_FAKEHOST_TOPLEVEL_ALREADY_EXISTS", slfh_name, tlfh_name);
return 0;
}
- if(irccasecmp(tlfh_name, "*")) {
- reply("HSMSG_
ACCESS_DENIED"
);
+ if(
!
irccasecmp(tlfh_name, "*")) {
+ reply("HSMSG_
TOPLEVEL_INVALID", tlfh_name
);
return 0;
}
hs_add_toplevel(tlfh_name);
return 0;
}
hs_add_toplevel(tlfh_name);
@@
-907,7
+907,7
@@
static MODCMD_FUNC(cmd_renamehost) {
reply("HSMSG_FAKEHOST_TOPLEVEL_ALREADY_EXISTS", new_slfh_name, new_tlfh_name);
return 0;
}
reply("HSMSG_FAKEHOST_TOPLEVEL_ALREADY_EXISTS", new_slfh_name, new_tlfh_name);
return 0;
}
- if(irccasecmp(new_tlfh_name, "*")) {
+ if(
!
irccasecmp(new_tlfh_name, "*")) {
reply("HSMSG_ACCESS_DENIED");
return 0;
}
reply("HSMSG_ACCESS_DENIED");
return 0;
}
@@
-932,6
+932,7
@@
static MODCMD_FUNC(cmd_renamehost) {
new_tlfh_name--;
*new_tlfh_name = '.';
reply("HSMSG_TOPLEVEL_INVALID", new_slfh_name);
new_tlfh_name--;
*new_tlfh_name = '.';
reply("HSMSG_TOPLEVEL_INVALID", new_slfh_name);
+ return 0;
}
struct hs_secondlevel *cslfh;
for(cslfh = tlfh->secondlevel; cslfh; cslfh = cslfh->next) {
}
struct hs_secondlevel *cslfh;
for(cslfh = tlfh->secondlevel; cslfh; cslfh = cslfh->next) {