[ https://issues.apache.org/jira/browse/AMQ-6445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15532390#comment-15532390 ]
ASF subversion and git services commented on AMQ-6445: ------------------------------------------------------ Commit 351faf26992f1406bf203b0cefd1238615baf88c in activemq's branch refs/heads/master from [~cshannon] [ https://git-wip-us.apache.org/repos/asf?p=activemq.git;h=351faf2 ] https://issues.apache.org/jira/browse/AMQ-6445 Fixing RandomAccessFile usage so that the file will be properly closed even if there is an exception > RandomAccessFile is not closed properly > --------------------------------------- > > Key: AMQ-6445 > URL: https://issues.apache.org/jira/browse/AMQ-6445 > Project: ActiveMQ > Issue Type: Bug > Affects Versions: 5.13.3 > Reporter: Kaloyan Spiridonov > Assignee: Christopher L. Shannon > Priority: Minor > Fix For: 5.15.0 > > > In DiskBenchmark class at 303 line and in Journal class at 290 line there is > RandomAccessFile created. After that this methods are called > XXXXXXX.setLength(size); > XXXXXXX.getChannel().force(true); > XXXXXXX.getChannel().transferTo(0, size, raf.getChannel());. > If one of them throw an Exception then the stream will not be closed. -- This message was sent by Atlassian JIRA (v6.3.4#6332)