Synchronize set/getSubnodeRelation() to prevent problems on multiprocessor machines
This commit is contained in:
parent
d8feb2620b
commit
5ebbfe70a3
1 changed files with 2 additions and 2 deletions
|
@ -617,7 +617,7 @@ public final class Node implements INode, Serializable {
|
||||||
*
|
*
|
||||||
* @param rel ...
|
* @param rel ...
|
||||||
*/
|
*/
|
||||||
public void setSubnodeRelation(String rel) {
|
public synchronized void setSubnodeRelation(String rel) {
|
||||||
if (((rel == null) && (this.subnodeRelation == null)) ||
|
if (((rel == null) && (this.subnodeRelation == null)) ||
|
||||||
((rel != null) && rel.equalsIgnoreCase(this.subnodeRelation))) {
|
((rel != null) && rel.equalsIgnoreCase(this.subnodeRelation))) {
|
||||||
return;
|
return;
|
||||||
|
@ -639,7 +639,7 @@ public final class Node implements INode, Serializable {
|
||||||
*
|
*
|
||||||
* @return ...
|
* @return ...
|
||||||
*/
|
*/
|
||||||
public String getSubnodeRelation() {
|
public synchronized String getSubnodeRelation() {
|
||||||
return subnodeRelation;
|
return subnodeRelation;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue