From: Andreas Gal Date: Sat, 25 Jun 2011 03:27:22 +0000 (-0400) Subject: fix issue #78, don't try to use 'in' operator on null X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=2f246236cba86fe9c0a9ff182851b05ef51ecf4b;p=pdf.js.git fix issue #78, don't try to use 'in' operator on null --- diff --git a/pdf.js b/pdf.js index a34cd7c..48fd742 100644 --- a/pdf.js +++ b/pdf.js @@ -979,7 +979,7 @@ function IsArray(v) { } function IsStream(v) { - return typeof v == "object" && "getChar" in v; + return typeof v == "object" && v != null && ("getChar" in v); } function IsRef(v) {