mirror of https://github.com/apache/activemq.git
changed unlock() method to use remove() instead of clearProperty
as this doesn't work on some platforms git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@603927 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
d4d9ba88b9
commit
0ac3f165dc
|
@ -503,9 +503,11 @@ public class KahaStore implements Store {
|
|||
|
||||
private synchronized void unlock() throws IOException {
|
||||
if (!DISABLE_LOCKING && (null != directory) && (null != lock)) {
|
||||
System.clearProperty(getPropertyKey());
|
||||
//clear property doesn't work on some platforms
|
||||
System.getProperties().remove(getPropertyKey());
|
||||
if (lock.isValid()) {
|
||||
lock.release();
|
||||
lock.channel().close();
|
||||
}
|
||||
lock = null;
|
||||
}
|
||||
|
|
|
@ -887,10 +887,12 @@ public class AMQPersistenceAdapter implements PersistenceAdapter, UsageListener,
|
|||
}
|
||||
|
||||
private synchronized void unlock() throws IOException {
|
||||
if (!disableLocking && (null != directory) && (null != lock)) {
|
||||
System.clearProperty(getPropertyKey());
|
||||
if (!disableLocking && (null != lock)) {
|
||||
//clear property doesn't work on some platforms
|
||||
System.getProperties().remove(getPropertyKey());
|
||||
if (lock.isValid()) {
|
||||
lock.release();
|
||||
lock.channel().close();
|
||||
}
|
||||
lock = null;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue