Index | Thread | Search

From:
Kirill A. Korinsky <kirill@korins.ky>
Subject:
x11/mplayer: fix for llvm22
To:
OpenBSD ports <ports@openbsd.org>
Date:
Thu, 21 May 2026 22:06:49 +0200

Download raw body.

Thread
ports@,

here a diff to fix x11/mplayer for llvm22.

Ok?

Index: Makefile
===================================================================
RCS file: /home/cvs/ports/x11/mplayer/Makefile,v
diff -u -p -r1.341 Makefile
--- Makefile	21 May 2026 16:25:02 -0000	1.341
+++ Makefile	21 May 2026 20:04:05 -0000
@@ -2,7 +2,7 @@ COMMENT=	movie player supporting many fo
 
 V=		20251123
 FFMPEG_V=	8.1.1
-REVISION=	1
+REVISION=	2
 DISTNAME=	mplayer-${V}
 CATEGORIES=	x11 multimedia
 SITES=		https://comstyle.com/source/
Index: patches/patch-sub_av_sub_c
===================================================================
RCS file: /home/cvs/ports/x11/mplayer/patches/patch-sub_av_sub_c,v
diff -u -p -r1.2 patch-sub_av_sub_c
--- patches/patch-sub_av_sub_c	10 Nov 2025 20:31:41 -0000	1.2
+++ patches/patch-sub_av_sub_c	21 May 2026 20:06:31 -0000
@@ -1,13 +1,14 @@
 Index: sub/av_sub.c
 --- sub/av_sub.c.orig
 +++ sub/av_sub.c
-@@ -30,8 +30,7 @@ void reset_avsub(struct sh_sub *sh)
+@@ -30,8 +30,8 @@ void reset_avsub(struct sh_sub *sh)
          AVCodecContext *ctx = sh->context;
          ctx->extradata = NULL;
          ctx->extradata_size = 0;
 -        avcodec_close(sh->context);
 -        av_freep(&sh->context);
-+        avcodec_free_context(&sh->context);
++        avcodec_free_context(&ctx);
++        sh->context = ctx;
      }
  }
  


-- 
wbr, Kirill