<html>
    <head>
      <base href="https://bugs.freedesktop.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW --- - Crash when using Wayland EGL platform"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=62362">62362</a>
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>mesa-dev@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Crash when using Wayland EGL platform
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux (All)
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>geomatsi@gmail.com
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>git
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Mesa core
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>Mesa
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Crash in Mesa when using Wayland EGL platform:

The root cause is incorrect parameter for wayland_roundtrip() in function
wayland_shm_display_init_screen (see file
src/gallium/state_trackers/egl/wayland/native_shm.c).

The following patch fixes the issue:

diff --git a/src/gallium/state_trackers/egl/wayland/native_shm.c
b/src/gallium/state_trackers/egl/wayland/native_shm.c
index a959237..e543619 100644
--- a/src/gallium/state_trackers/egl/wayland/native_shm.c
+++ b/src/gallium/state_trackers/egl/wayland/native_shm.c
@@ -163,7 +163,8 @@ wayland_shm_display_init_screen(struct native_display
*ndpy)
       return FALSE;

    if (shmdpy->base.formats == 0)
-      wayland_roundtrip(shmdpy->base.dpy);
+      wayland_roundtrip(&shmdpy->base);
+
    if (shmdpy->base.formats == 0)
       return FALSE;</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>