diff --git a/examples/idle.c b/examples/idle.c index 0f3a7f804..6faa1d7d3 100644 --- a/examples/idle.c +++ b/examples/idle.c @@ -127,7 +127,7 @@ int main(int argc, char *argv[]) { wl_registry_add_listener(registry, ®istry_listener, NULL); wl_display_dispatch(display); wl_display_roundtrip(display); - free(registry); + wl_registry_destroy(registry); if (idle_manager == NULL) { fprintf(stderr, "display doesn't support idle protocol\n");