Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
mpv (0.38.0-1deepin3) unstable; urgency=medium

* chore: Update version to 0.38.0-1deepin3
* fix: add vaapi null pointer crash patch to series

-- zhanghongyuan <zhanghongyuan@uniontech.com> Mon, 15 Dec 2025 09:54:24 +0800

mpv (0.38.0-1deepin2) unstable; urgency=medium

* chore: Update version to 0.38.0-1deepin2
Expand Down
50 changes: 50 additions & 0 deletions debian/patches/fix-vaapi-nullpter-crush.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
Index: mpv/video/out/vo_vaapi.c
===================================================================
--- mpv.orig/video/out/vo_vaapi.c
+++ mpv/video/out/vo_vaapi.c
@@ -410,19 +410,11 @@ static void va_pool_set_allocator(struct
mp_image_pool_set_lru(pool);
}

-static void flush_output_surfaces(struct priv *p)
-{
- for (int n = 0; n < MAX_OUTPUT_SURFACES; n++)
- mp_image_unrefp(&p->output_surfaces[n]);
- p->output_surface = 0;
- p->visible_surface = 0;
-}
-
// See flush_surfaces() remarks - the same applies.
static void free_video_specific(struct priv *p)
{
- flush_output_surfaces(p);
-
+ p->output_surface = 0;
+ p->visible_surface = 0;
mp_image_unrefp(&p->black_surface);

for (int n = 0; n < MAX_OUTPUT_SURFACES; n++)
@@ -434,7 +426,6 @@ static void free_video_specific(struct p

static bool alloc_swdec_surfaces(struct priv *p, int w, int h, int imgfmt)
{
- free_video_specific(p);
for (int i = 0; i < MAX_OUTPUT_SURFACES; i++) {
p->swdec_surfaces[i] = mp_image_pool_get(p->pool, IMGFMT_VAAPI, w, h);
if (va_surface_alloc_imgfmt(p, p->swdec_surfaces[i], imgfmt) < 0)
@@ -581,14 +572,12 @@ static void draw_frame(struct vo *vo, st
struct mp_image *dst = p->swdec_surfaces[p->output_surface];
if (!dst || va_surface_upload(p, dst, mpi) < 0) {
MP_WARN(vo, "Could not upload surface.\n");
- talloc_free(mpi);
return;
}
mp_image_copy_attributes(dst, mpi);
- mpi = mp_image_new_ref(dst);
+ mpi = dst;
}

- talloc_free(p->output_surfaces[p->output_surface]);
p->output_surfaces[p->output_surface] = mpi;

draw_osd(vo);
1 change: 1 addition & 0 deletions debian/patches/series
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ pgv-flower-screen.patch
vdpau-render.patch
Fix-the-problem-of-the-full-screen-crash.patch
fix-mpv.patch
fix-vaapi-nullpter-crush.patch
Loading