Exit on mode change intead of crashing

pull/55/head
Andri Yngvason 2020-07-07 10:08:27 +00:00
parent 9d2e22b9bd
commit ef74911298
1 changed files with 5 additions and 2 deletions

View File

@ -497,8 +497,11 @@ void wayvnc_process_frame(struct wayvnc* self)
self->screencopy.back->height);
} else {
// TODO: Reallocate
assert(width == nvnc_fb_get_width(self->buffer));
assert(height == nvnc_fb_get_height(self->buffer));
if (width != nvnc_fb_get_width(self->buffer) ||
height != nvnc_fb_get_height(self->buffer)) {
wayvnc_exit(self);
return;
}
}
struct pixman_region16 txdamage, refined;