diff --git a/audit/src/main/java/org/wildfly/security/audit/FileAuditEndpoint.java b/audit/src/main/java/org/wildfly/security/audit/FileAuditEndpoint.java index ea1605b22de..c3e2632a621 100644 --- a/audit/src/main/java/org/wildfly/security/audit/FileAuditEndpoint.java +++ b/audit/src/main/java/org/wildfly/security/audit/FileAuditEndpoint.java @@ -70,7 +70,7 @@ public class FileAuditEndpoint implements AuditEndpoint { } void setFile(final File file) throws IOException { - boolean ok = false; + boolean isFileSet = false; final FileOutputStream fos = new FileOutputStream(file, true); try { final Writer writer = new OutputStreamWriter(new BufferedOutputStream(fos), this.charset); @@ -78,14 +78,14 @@ void setFile(final File file) throws IOException { this.fileDescriptor = fos.getFD(); this.writer = writer; this.file = file; - ok = true; + isFileSet = true; } finally { - if (! ok) { + if (! isFileSet) { safeClose(writer); } } } finally { - if (! ok) { + if (! isFileSet) { safeClose(fos); } } @@ -121,7 +121,7 @@ void write(String toWrite) throws IOException { * This method is NO-OP by default. It is intended to be overridden by subclasses * which need to perform some operation before every writing into the target local file. * - * This method can be invoked only in synchronization block surrounding one log message processing. + * This method can be invisFileSeted only in synchronization block surrounding one log message processing. * * @param instant time of the message acceptance */