From c766e47b7095568509173e49fb049ff1b501b71d Mon Sep 17 00:00:00 2001 From: Niklas Haas Date: Tue, 16 Feb 2021 14:20:26 +0100 Subject: vo_gpu: don't abort() if plane tex creation fails In this case, we just treat all uploads as automatically failing. That error path already exists and is already handled correctly. Fixes #8566 --- video/out/gpu/video.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'video') diff --git a/video/out/gpu/video.c b/video/out/gpu/video.c index 2aae3171e6..e5a9737473 100644 --- a/video/out/gpu/video.c +++ b/video/out/gpu/video.c @@ -957,9 +957,6 @@ static void init_video(struct gl_video *p) params.w, params.h); plane->tex = ra_tex_create(p->ra, ¶ms); - if (!plane->tex) - abort(); // shit happens - p->use_integer_conversion |= format->ctype == RA_CTYPE_UINT; } } @@ -3588,6 +3585,10 @@ static bool pass_upload_image(struct gl_video *p, struct mp_image *mpi, uint64_t timer_pool_start(p->upload_timer); for (int n = 0; n < p->plane_count; n++) { struct texplane *plane = &vimg->planes[n]; + if (!plane->tex) { + timer_pool_stop(p->upload_timer); + goto error; + } struct ra_tex_upload_params params = { .tex = plane->tex, -- cgit v1.2.3