Synchronize set/getSubnodeRelation() to prevent problems on multiprocessor machines

This commit is contained in:
grob 2005-07-06 11:42:36 +00:00
parent d8feb2620b
commit 5ebbfe70a3

View file

@ -617,7 +617,7 @@ public final class Node implements INode, Serializable {
*
* @param rel ...
*/
public void setSubnodeRelation(String rel) {
public synchronized void setSubnodeRelation(String rel) {
if (((rel == null) && (this.subnodeRelation == null)) ||
((rel != null) && rel.equalsIgnoreCase(this.subnodeRelation))) {
return;
@ -639,7 +639,7 @@ public final class Node implements INode, Serializable {
*
* @return ...
*/
public String getSubnodeRelation() {
public synchronized String getSubnodeRelation() {
return subnodeRelation;
}