summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTim Watson <tim@rabbitmq.com>2013-06-06 10:39:44 +0100
committerTim Watson <tim@rabbitmq.com>2013-06-06 10:39:44 +0100
commit818fa1245361271114ffc66d418ea6f8c9d5f10e (patch)
tree9beff2127e1f134c8d0aeec80d097ab4e1422ce7 /src
parenta8d762e8e87b6893796895df576a0ced19cc1574 (diff)
parentbc7d5a6d84b788e209fc529b0a780f810890332e (diff)
downloadrabbitmq-server-git-818fa1245361271114ffc66d418ea6f8c9d5f10e.tar.gz
merge bug25573 into stable
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_access_control.erl7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/rabbit_access_control.erl b/src/rabbit_access_control.erl
index 1638726863..cbe89a17a1 100644
--- a/src/rabbit_access_control.erl
+++ b/src/rabbit_access_control.erl
@@ -68,8 +68,11 @@ check_vhost_access(User = #user{ username = Username,
auth_backend = Module }, VHostPath) ->
check_access(
fun() ->
- rabbit_vhost:exists(VHostPath) andalso
- Module:check_vhost_access(User, VHostPath)
+ %% TODO this could be an andalso shortcut under >R13A
+ case rabbit_vhost:exists(VHostPath) of
+ false -> false;
+ true -> Module:check_vhost_access(User, VHostPath)
+ end
end,
"~s failed checking vhost access to ~s for ~s: ~p~n",
[Module, VHostPath, Username],