Sisyphus repositório
Última atualização: 1 outubro 2023 | SRPMs: 18631 | Visitas: 37903558
en ru br
ALT Linux repositórios
S:1.6.4-alt4

Group :: Educação
RPM: OpenBoard

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs e FR  Repocop 

Patch: 0002-fix-avoid-taking-address-of-initializer-list.patch
Download


From 347af2a56804100c589766ff20768914d8a04903 Mon Sep 17 00:00:00 2001
From: letsfindaway <me@letsfindaway.de>
Date: Thu, 15 Sep 2022 11:55:17 +0200
Subject: [PATCH 2/2] fix: avoid taking address of initializer list
- FFmpeg example code was used for UBFFmpegVideoEncoder.cpp
- channel layout was initialized by taking address of an initializer
- at least for some compilers this fails, as it is an rvalue
- using an explicit variable avoids this
---
 src/podcast/ffmpeg/UBFFmpegVideoEncoder.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/podcast/ffmpeg/UBFFmpegVideoEncoder.cpp b/src/podcast/ffmpeg/UBFFmpegVideoEncoder.cpp
index 4fd84d740..805ff77e1 100644
--- a/src/podcast/ffmpeg/UBFFmpegVideoEncoder.cpp
+++ b/src/podcast/ffmpeg/UBFFmpegVideoEncoder.cpp
@@ -455,7 +455,8 @@ bool UBFFmpegVideoEncoder::init()
         c->channel_layout = AV_CH_LAYOUT_STEREO;
         c->channels  = av_get_channel_layout_nb_channels(c->channel_layout);
 #else
-        av_channel_layout_copy(&c->ch_layout, &(AVChannelLayout)AV_CHANNEL_LAYOUT_STEREO);
+        AVChannelLayout layout = AV_CHANNEL_LAYOUT_STEREO;
+        av_channel_layout_copy(&c->ch_layout, &layout);
 #endif
 
         //deprecated on ffmpeg 4
-- 
2.33.8
 
projeto & código: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
mantenedor atual: Michael Shigorin
mantenedor da tradução: Fernando Martini aka fmartini © 2009