You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@poi.apache.org by ma...@apache.org on 2010/11/22 12:10:01 UTC

svn commit: r1037670 - /poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/model/PicturesTable.java

Author: maxcom
Date: Mon Nov 22 11:10:01 2010
New Revision: 1037670

URL: http://svn.apache.org/viewvc?rev=1037670&view=rev
Log:
hwpf: Ignore null argument in PicturesTable.hasPicture

Modified:
    poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/model/PicturesTable.java

Modified: poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/model/PicturesTable.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/model/PicturesTable.java?rev=1037670&r1=1037669&r2=1037670&view=diff
==============================================================================
--- poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/model/PicturesTable.java (original)
+++ poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/model/PicturesTable.java Mon Nov 22 11:10:01 2010
@@ -87,6 +87,10 @@ public final class PicturesTable
    * @param run
    */
   public boolean hasPicture(CharacterRun run) {
+    if (run==null) {
+        return false;
+    }
+
     if (run.isSpecialCharacter() && !run.isObj() && !run.isOle2() && !run.isData()) {
        // Image should be in it's own run, or in a run with the end-of-special marker
        if("\u0001".equals(run.text()) || "\u0001\u0015".equals(run.text())) {



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org