<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>41896</bug_id>
          
          <creation_ts>2010-07-08 13:32:34 -0700</creation_ts>
          <short_desc>Crash under allScriptsInPDFDocument() in WebPDFDocumentExtras.mm for certain PDFs</short_desc>
          <delta_ts>2010-07-08 14:15:51 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>PDF</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.6</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Mike Thole">mthole</reporter>
          <assigned_to name="Mike Thole">mthole</assigned_to>
          
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>248489</commentid>
    <comment_count>0</comment_count>
    <who name="Mike Thole">mthole</who>
    <bug_when>2010-07-08 13:32:34 -0700</bug_when>
    <thetext>Certain PDF files can cause a crash under allScriptsInPDFDocument() in WebPDFDocumentExtras.mm.

Sample crash log:

   1 com.apple.CoreFoundation       0x7fff8df5da72 CFDataGetBytePtr + 0x12 (CFInternal.h:602)
   2 com.apple.WebKit               0x7fff95670cb7 allScriptsInPDFDocument(PDFDocument*) + 0x167 (WebPDFDocumentExtras.mm:115)
   3 com.apple.WebKit               0x7fff95670793 -[WebPDFRepresentation finishedLoadingWithDataSource:] + 0x143 (WebPDFRepresentation.mm:129)
   4 com.apple.WebCore              0x7fff93e1b6ec WebCore::FrameLoader::finishedLoadingDocument(WebCore::DocumentLoader*) + 0x30 (FrameLoader.cpp:2732)
   5 com.apple.WebCore              0x7fff93e18538 WebCore::DocumentLoader::finishedLoading() + 0x38 (DocumentLoader.cpp:267)
   6 com.apple.WebCore              0x7fff93eac292 WebCore::FrameLoader::finishedLoading() + 0x48 (ResourceErrorBase.h:40)
   7 com.apple.WebCore              0x7fff93eac1ad WebCore::MainResourceLoader::didFinishLoading() + 0x2f (MainResourceLoader.cpp:424)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>248492</commentid>
    <comment_count>1</comment_count>
    <who name="Mike Thole">mthole</who>
    <bug_when>2010-07-08 13:34:01 -0700</bug_when>
    <thetext>&lt;rdar://problem/8105430&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>248495</commentid>
    <comment_count>2</comment_count>
      <attachid>60943</attachid>
    <who name="Mike Thole">mthole</who>
    <bug_when>2010-07-08 13:38:19 -0700</bug_when>
    <thetext>Created attachment 60943
Proposed patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>248534</commentid>
    <comment_count>3</comment_count>
    <who name="Mike Thole">mthole</who>
    <bug_when>2010-07-08 14:15:51 -0700</bug_when>
    <thetext>Committed revision 62835.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>60943</attachid>
            <date>2010-07-08 13:38:19 -0700</date>
            <delta_ts>2010-07-08 14:12:04 -0700</delta_ts>
            <desc>Proposed patch</desc>
            <filename>textmate stdin QR4quj.txt</filename>
            <type>text/plain</type>
            <size>1382</size>
            <attacher name="Mike Thole">mthole</attacher>
            
              <data encoding="base64">SW5kZXg6IFdlYktpdC9tYWMvQ2hhbmdlTG9nCj09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KLS0tIFdlYktpdC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4IEBAIE5TQXJyYXkgKmFsbFNjcmlwdHNJblBERkRvY3VtZW50KFBERkRv
Y3UKICAgICAgICAgaWYgKENHUERGRGljdGlvbmFyeUdldFN0cmVhbShqYXZhU2NyaXB0QWN0aW9u
LCAiSlMiLCAmc3RyZWFtKSkgewogICAgICAgICAgICAgQ0dQREZEYXRhRm9ybWF0IGZvcm1hdDsK
ICAgICAgICAgICAgIGRhdGEuYWRvcHRDRihDR1BERlN0cmVhbUNvcHlEYXRhKHN0cmVhbSwgJmZv
cm1hdCkpOworICAgICAgICAgICAgaWYgKCFkYXRhKQorICAgICAgICAgICAgICAgIGNvbnRpbnVl
OwogICAgICAgICAgICAgYnl0ZXMgPSBDRkRhdGFHZXRCeXRlUHRyKGRhdGEuZ2V0KCkpOwogICAg
ICAgICAgICAgbGVuZ3RoID0gQ0ZEYXRhR2V0TGVuZ3RoKGRhdGEuZ2V0KCkpOwogICAgICAgICB9
IGVsc2UgaWYgKENHUERGRGljdGlvbmFyeUdldFN0cmluZyhqYXZhU2NyaXB0QWN0aW9uLCAiSlMi
LCAmc3RyaW5nKSkgewo=
</data>
<flag name="review"
          id="48799"
          type_id="1"
          status="+"
          setter="darin"
    />
          </attachment>
      

    </bug>

</bugzilla>