diff options
author | Andrew C. Oliver <acoliver@apache.org> | 2002-10-01 21:43:16 +0000 |
---|---|---|
committer | Andrew C. Oliver <acoliver@apache.org> | 2002-10-01 21:43:16 +0000 |
commit | cfde042818dbac0b16072a05f31f78e5b72ccce3 (patch) | |
tree | 445a0e63688350fe5bedc38a74fa003513587b9e | |
parent | e191c1b553a363ce49f79c2419d6862fa89243b9 (diff) | |
download | poi-cfde042818dbac0b16072a05f31f78e5b72ccce3.tar.gz poi-cfde042818dbac0b16072a05f31f78e5b72ccce3.zip |
fixed bug http://nagoya.apache.org/bugzilla/show_bug.cgi?id=13092 NameRecord
no longer throws an NPE. I think this is due to unknown PTGs. -Andy
PR:
Obtained from:
Submitted by:
Reviewed by:
git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@352875 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | src/java/org/apache/poi/hssf/record/NameRecord.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/java/org/apache/poi/hssf/record/NameRecord.java b/src/java/org/apache/poi/hssf/record/NameRecord.java index b861a9e6e4..be3c9d6c05 100644 --- a/src/java/org/apache/poi/hssf/record/NameRecord.java +++ b/src/java/org/apache/poi/hssf/record/NameRecord.java @@ -755,7 +755,8 @@ public class NameRecord extends Record { .append("\n"); buffer.append(" .Name (Unicode text) = ").append( field_12_name_text ) .append("\n"); - buffer.append(" .Formula data (RPN token array without size field) = ").append( HexDump.toHex( field_13_raw_name_definition ) ) + buffer.append(" .Formula data (RPN token array without size field) = ").append( HexDump.toHex( + ((field_13_raw_name_definition != null) ? field_13_raw_name_definition : new byte[0] ) ) ) .append("\n"); buffer.append(" .Menu text (Unicode string without length field) = ").append( field_14_custom_menu_text ) .append("\n"); |