[MPlayer-dev-eng] [PATCH] Fix a sndio crash when exiting in muted state

Brad Smith brad at comstyle.com
Tue Mar 21 13:55:28 EET 2023


ping.

On March 14, 2023 6:31:39 a.m. Brad Smith <brad-at-comstyle.com at ffmpeg.org> 
wrote:

> Patch from Theo Buehler <tb at openbsd.org>
>
> CVSROOT: /cvs
> Module name: ports
> Changes by: tb at cvs.openbsd.org 2023/03/14 04:08:13
>
> Modified files:
> x11/mplayer    : Makefile
> x11/mplayer/patches: patch-libao2_ao_sndio_c
>
> Log message:
> mplayer: fix a crash when exiting in muted state
>
> Muting mplayer with 'm', then hitting '<enter>' segfaults mplayer since it
> tries to unmute itself after uninitializing the sndio backend. Clear the
> havevol flag on uninit() to block subsequent AOCONTROL_{GET,SET}_VOLUME
> operations.
>
> Fix suggested by and ok ratchov
>
>
> Index: libao2/ao_sndio.c
> ===================================================================
> --- libao2/ao_sndio.c (revision 38412)
> +++ libao2/ao_sndio.c (working copy)
> @@ -159,6 +159,7 @@
>     pfds = NULL;
>     sio_close(hdl);
>     hdl = NULL;
> +    havevol = 0;
>     return 0;
> }
>
> @@ -172,6 +173,7 @@
>     hdl = NULL;
>     free(pfds);
>     pfds = NULL;
> +    havevol = 0;
> }
>
> /*
> _______________________________________________
> MPlayer-dev-eng mailing list
> MPlayer-dev-eng at mplayerhq.hu
> https://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng


Sent with Aqua Mail for Android


More information about the MPlayer-dev-eng mailing list