<html>
    <head>
      <base href="https://bugs.webkit.org/">
    </head>
    <body><span class="vcard"><a class="email" href="mailto:aperez@igalia.com" title="Adrian Perez <aperez@igalia.com>"> <span class="fn">Adrian Perez</span></a>
</span> changed
          <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [GTK][a11y] Add implementation of document interface when building with ATSPI"
   href="https://bugs.webkit.org/show_bug.cgi?id=232755">bug 232755</a>
          <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">CC</td>
           <td>
                
           </td>
           <td>aperez@igalia.com
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Attachment #444813 Flags</td>
           <td>review?
           </td>
           <td>review-
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [GTK][a11y] Add implementation of document interface when building with ATSPI"
   href="https://bugs.webkit.org/show_bug.cgi?id=232755#c4">Comment # 4</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [GTK][a11y] Add implementation of document interface when building with ATSPI"
   href="https://bugs.webkit.org/show_bug.cgi?id=232755">bug 232755</a>
              from <span class="vcard"><a class="email" href="mailto:aperez@igalia.com" title="Adrian Perez <aperez@igalia.com>"> <span class="fn">Adrian Perez</span></a>
</span></b>
        <pre>Comment on <span class=""><a href="attachment.cgi?id=444813&action=diff" name="attach_444813" title="Patch">attachment 444813</a> <a href="attachment.cgi?id=444813&action=edit" title="Patch">[details]</a></span>
Patch

View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=444813&action=review">https://bugs.webkit.org/attachment.cgi?id=444813&action=review</a>

<span class="quote">> Source/WebCore/accessibility/atspi/AccessibilityObjectDocumentAtspi.cpp:112
> +            return map;</span >

I would first check m_coreObject and do the early return, after that we know
that it will not be null and avoid checking it again. I am thinking of this:

  if (!m_coreObject)
      return map;

  m_coreObject->updateBackingStore();
  auto* document = m_coreObject->document();
  // ...rest of the code as it was...

<span class="quote">> Source/WebCore/accessibility/atspi/AccessibilityObjectDocumentAtspi.cpp:148
> +            return { };</span >

Same here, there are two null-checks on m_coreObject one right after the other.</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>