avoid warning: check if property node exists instead of throw/catch exception

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1410324 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yegor Kozlov 2012-11-16 12:58:45 +00:00
parent 133c0d7c0b
commit c7c321b0f1

View File

@ -148,7 +148,7 @@ public abstract class POIDocument {
*/
protected PropertySet getPropertySet(String setName) {
//directory can be null when creating new documents
if(directory == null) return null;
if(directory == null || !directory.hasEntry(setName)) return null;
DocumentInputStream dis;
try {