mirror of https://github.com/apache/activemq.git
resolve fd leak in locking logic, cause slave to exhaust fds and fail
git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@808041 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
30db300a1a
commit
589f9241fe
|
@ -55,7 +55,9 @@ public class LockFile {
|
|||
}
|
||||
|
||||
IOHelper.mkdirs(file.getParentFile());
|
||||
if (readFile == null) {
|
||||
readFile = new RandomAccessFile(file, "rw");
|
||||
}
|
||||
if (lock == null) {
|
||||
try {
|
||||
lock = readFile.getChannel().tryLock();
|
||||
|
|
Loading…
Reference in New Issue