Check calloc return value

This commit is contained in:
Kenny Levinsen 2019-12-22 01:00:45 +01:00 committed by Jente Hidskes
parent 06ada15661
commit 739ba1fe65

View file

@ -363,6 +363,10 @@ handle_new_output(struct wl_listener *listener, void *data)
}
struct cg_output *output = calloc(1, sizeof(struct cg_output));
if (!output) {
return;
}
output->wlr_output = wlr_output;
output->server = server;
output->damage = wlr_output_damage_create(wlr_output);