diff options
Diffstat (limited to 'src/main/java/org/openslx/libvirt/xml')
-rw-r--r-- | src/main/java/org/openslx/libvirt/xml/LibvirtXmlNode.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/org/openslx/libvirt/xml/LibvirtXmlNode.java b/src/main/java/org/openslx/libvirt/xml/LibvirtXmlNode.java index a941acb..7f3818f 100644 --- a/src/main/java/org/openslx/libvirt/xml/LibvirtXmlNode.java +++ b/src/main/java/org/openslx/libvirt/xml/LibvirtXmlNode.java @@ -319,7 +319,9 @@ public class LibvirtXmlNode implements LibvirtXmlCreatable, LibvirtXmlEditable if ( node != null ) { Node attribute = node.getAttributes().getNamedItem( attributeName ); - node.getAttributes().removeNamedItem( attribute.getNodeName() ); + if ( attribute != null ) { + node.getAttributes().removeNamedItem( attribute.getNodeName() ); + } } } |