Sophie

Sophie

distrib > Mageia > 6 > x86_64 > media > tainted-release-src > by-pkgid > 4b447df0433bf916f47e9164b8b70ac4 > files > 10

mplayer-1.3.0-11.mga6.tainted.src.rpm

diff -up MPlayer-1.2/libmpcodecs/ad_spdif.c.pts MPlayer-1.2/libmpcodecs/ad_spdif.c
--- MPlayer-1.2/libmpcodecs/ad_spdif.c.pts	2015-06-10 14:24:28.000000000 +0200
+++ MPlayer-1.2/libmpcodecs/ad_spdif.c	2015-12-31 21:18:38.635968903 +0100
@@ -211,6 +211,11 @@ static int init(sh_audio_t *sh)
     default:
         break;
     }
+    
+    // a call to avformat_write_header() is needed to prevent segfaults, 
+    // but this should replace the earlier call to lavf_ctx->oformat->write_header() 
+    // somehow...
+    avformat_write_header(lavf_ctx, NULL);
 
     return 1;