simple clients: flush before destroying wl_display

Flush our pending destroy requests to the server before destroying the
wl_display.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
This commit is contained in:
Pekka Paalanen 2011-12-15 10:07:52 +02:00
parent 2c2c1060e9
commit fb850c4e0f
2 changed files with 2 additions and 0 deletions

View File

@ -386,6 +386,7 @@ main(int argc, char **argv)
if (display.compositor)
wl_compositor_destroy(display.compositor);
wl_display_flush(display.display);
wl_display_destroy(display.display);
return 0;

View File

@ -235,6 +235,7 @@ destroy_display(struct display *display)
if (display->compositor)
wl_compositor_destroy(display->compositor);
wl_display_flush(display->display);
wl_display_destroy(display->display);
free(display);
}