diff options
Diffstat (limited to 'qpid/java')
| -rw-r--r-- | qpid/java/broker/src/main/java/org/apache/qpid/server/security/auth/database/AbstractPasswordFilePrincipalDatabase.java | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/qpid/java/broker/src/main/java/org/apache/qpid/server/security/auth/database/AbstractPasswordFilePrincipalDatabase.java b/qpid/java/broker/src/main/java/org/apache/qpid/server/security/auth/database/AbstractPasswordFilePrincipalDatabase.java index 9277b80b99..7088fae50c 100644 --- a/qpid/java/broker/src/main/java/org/apache/qpid/server/security/auth/database/AbstractPasswordFilePrincipalDatabase.java +++ b/qpid/java/broker/src/main/java/org/apache/qpid/server/security/auth/database/AbstractPasswordFilePrincipalDatabase.java @@ -358,19 +358,26 @@ public abstract class AbstractPasswordFilePrincipalDatabase<U extends PasswordPr catch(IOException e) { getLogger().error("Unable to create the new password file: " + e); - throw new IOException("Unable to create the new password file" + e); + throw new IOException("Unable to create the new password file",e); } finally { - if (reader != null) + + try { - reader.close(); + if (reader != null) + { + reader.close(); + } } - - if (writer != null) + finally { - writer.close(); + if (writer != null) + { + writer.close(); + } } + } swapTempFileToLive(tmp); |
