aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/examples/src/org/apache/poi/hpsf/examples/CopyCompare.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/examples/src/org/apache/poi/hpsf/examples/CopyCompare.java b/src/examples/src/org/apache/poi/hpsf/examples/CopyCompare.java
index 0f47704c97..0ac755d2d4 100644
--- a/src/examples/src/org/apache/poi/hpsf/examples/CopyCompare.java
+++ b/src/examples/src/org/apache/poi/hpsf/examples/CopyCompare.java
@@ -169,7 +169,9 @@ public final class CopyCompare {
de = (de.hasEntry(subDir)) ? (DirectoryEntry)de.getEntry(subDir) : de.createDirectory(subDir);
}
- de.createDocument(event.getName(), is);
+ if (event.getName() != null) {
+ de.createDocument(event.getName(), is);
+ }
}
} catch (HPSFException | IOException ex) {