summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/acl/AclPlugin.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/qpid/acl/AclPlugin.cpp')
-rw-r--r--cpp/src/qpid/acl/AclPlugin.cpp13
1 files changed, 4 insertions, 9 deletions
diff --git a/cpp/src/qpid/acl/AclPlugin.cpp b/cpp/src/qpid/acl/AclPlugin.cpp
index 7310139041..4c6efa19dd 100644
--- a/cpp/src/qpid/acl/AclPlugin.cpp
+++ b/cpp/src/qpid/acl/AclPlugin.cpp
@@ -62,15 +62,10 @@ struct AclPlugin : public Plugin {
if (acl) throw Exception("ACL plugin cannot be initialized twice in one process.");
- if (values.aclFile.at(0) == '/')
- {
- values.aclFile = values.aclFile;
- }
- else
- {
- std::ostringstream oss;
- oss << b.getDataDir().getPath() << "/" << values.aclFile;
- values.aclFile = oss.str();
+ if (values.aclFile.at(0) != '/' && !b.getDataDir().getPath().empty()) {
+ std::ostringstream oss;
+ oss << b.getDataDir().getPath() << "/" << values.aclFile;
+ values.aclFile = oss.str();
}
acl = new Acl(values, b);