summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMickaël Rémond <mickael.remond@process-one.net>2006-07-18 12:29:17 +0000
committerMickaël Rémond <mickael.remond@process-one.net>2006-07-18 12:29:17 +0000
commite965aae60a71b5c6ccb9c7674d6570a30a0cb89e (patch)
treed1a29b647dbfa6602cdf4355acb3777a85ee0a8e
parent* src/web/ejabberd_web_admin.erl: User creation form now creates (diff)
* src/acl.erl: The server does not crash anymore on wrong acl rule. Add
rule error message in log file (EJAB-118). SVN Revision: 589
-rw-r--r--ChangeLog5
-rw-r--r--src/acl.erl8
2 files changed, 12 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 8bf619f6..884c6da6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-07-16 Mickael Remond <mickael.remond@process-one.net>
+
+ * src/acl.erl: The server does not crash anymore on wrong acl rule. Add
+ rule error message in log file.
+
2006-07-07 Mickael Remond <mickael.remond@process-one.net>
* src/web/ejabberd_web_admin.erl: User creation form now creates the
diff --git a/src/acl.erl b/src/acl.erl
index 61c997f8..a4417a59 100644
--- a/src/acl.erl
+++ b/src/acl.erl
@@ -171,7 +171,13 @@ match_acl(ACL, JID, Host) ->
is_glob_match(Server, SR);
{node_glob, UR, SR} ->
is_glob_match(Server, SR) andalso
- is_glob_match(User, UR)
+ is_glob_match(User, UR);
+ WrongSpec ->
+ ?ERROR_MSG(
+ "Wrong ACL expression: ~p~n"
+ "Check your config file and reload it with the override_acls option enabled",
+ [WrongSpec]),
+ false
end
end,
ets:lookup(acl, {ACL, global}) ++