<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - AX: Crash at AccessibilityRenderObject::computeAccessibilityIsIgnored const + 552"
   href="https://bugs.webkit.org/show_bug.cgi?id=161276#c6">Comment # 6</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - AX: Crash at AccessibilityRenderObject::computeAccessibilityIsIgnored const + 552"
   href="https://bugs.webkit.org/show_bug.cgi?id=161276">bug 161276</a>
              from <span class="vcard"><a class="email" href="mailto:cfleizach&#64;apple.com" title="chris fleizach &lt;cfleizach&#64;apple.com&gt;"> <span class="fn">chris fleizach</span></a>
</span></b>
        <pre>Maybe we can just do

RenderObject protect(mrenderer)

Then access it everywhere with

protect.isBR() and likewise with dot operator

(In reply to <a href="show_bug.cgi?id=161276#c5">comment #5</a>)
<span class="quote">&gt; Comment on <span class=""><a href="attachment.cgi?id=287168&amp;action=diff" name="attach_287168" title="Patch">attachment 287168</a> <a href="attachment.cgi?id=287168&amp;action=edit" title="Patch">[details]</a></span>
&gt; Patch
&gt; 
&gt; View in context:
&gt; <a href="https://bugs.webkit.org/attachment.cgi?id=287168&amp;action=review">https://bugs.webkit.org/attachment.cgi?id=287168&amp;action=review</a>
&gt; 
&gt; &gt;&gt;&gt; Source/WebCore/accessibility/AccessibilityRenderObject.cpp:1158
&gt; &gt;&gt;&gt; +    RenderObject* protectedRenderer(m_renderer);
&gt; &gt;&gt; 
&gt; &gt;&gt; does this hold onto the object? or just make a copy of the pointer?
&gt; &gt; 
&gt; &gt; Good point, I'll double check. The RenderObject is not ref counted.
&gt; 
&gt; Since m_renderer is just a raw pointer, we have no way to know anything
&gt; about the ownership and hold onto it easily (I did a lot of searches on
&gt; smart pointers but I don't think we want to declare sole ownership within
&gt; this function). A copy of the RenderObject might work but I suspect it will
&gt; affect the performance quite a lot. The easiest way I can think of (since we
&gt; are not sure what is causing the m_renderer being null) is to null check at
&gt; all the place within this function when we are accessing m_renderer, but
&gt; that seems to be very ugly.</span ></pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>