[packages/dvanalyzer] Rel 3
arekm
arekm at pld-linux.org
Thu May 21 15:23:42 CEST 2026
commit a3be3189504002b7eda91e6db737c9cc0fbd1a5b
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Thu May 21 15:23:26 2026 +0200
Rel 3
dvanalyzer-const-correctness.patch | 18 ++++++++++++++++++
dvanalyzer.spec | 5 ++++-
2 files changed, 22 insertions(+), 1 deletion(-)
---
diff --git a/dvanalyzer.spec b/dvanalyzer.spec
index 4a5fccd..d6e7fa8 100644
--- a/dvanalyzer.spec
+++ b/dvanalyzer.spec
@@ -2,11 +2,12 @@ Summary: Technical and tag information about video or audio file (CLI)
Summary(pl.UTF-8): Informacje techniczne i oznaczenia dotyczące pliku wideo lub audio (CLI)
Name: dvanalyzer
Version: 1.4.2
-Release: 2
+Release: 3
License: GPL v3+
Group: Applications/Multimedia
Source0: https://mediaarea.net/download/source/dvanalyzer/%{version}/%{name}_%{version}.tar.xz
# Source0-md5: 207b881f4762cc06cb5652fdddcb60ee
+Patch0: %{name}-const-correctness.patch
URL: https://mediaarea.net/DVAnalyzer
BuildRequires: Qt5Gui-devel >= 5
BuildRequires: Qt5Widgets-devel >= 5
@@ -77,6 +78,8 @@ klatki w poszczególnych nagraniach itd.
%prep
%setup -q -n AVPS_DV_Analyzer
+%undos Source/Common/Core.cpp
+%patch -P0 -p0
%undos *.html *.txt Release/*.txt
chmod 644 *.html *.txt Release/*.txt
diff --git a/dvanalyzer-const-correctness.patch b/dvanalyzer-const-correctness.patch
new file mode 100644
index 0000000..f7d3807
--- /dev/null
+++ b/dvanalyzer-const-correctness.patch
@@ -0,0 +1,18 @@
+Fix const-correctness: ToPush.Errors is const char* in the upstream struct,
+so memcpy() into it fails with GCC. Allocate via a local non-const pointer
+first, then assign to the const member.
+
+--- Source/Common/Core.cpp.orig
++++ Source/Common/Core.cpp
+@@ -142,8 +142,9 @@
+ if (ToPush.Errors)
+ {
+ size_t SizeToCopy=std::strlen(FrameData->Errors)+1;
+- ToPush.Errors=new char[SizeToCopy];
+- std::memcpy(ToPush.Errors, FrameData->Errors, SizeToCopy);
++ char* Buf=new char[SizeToCopy];
++ std::memcpy(Buf, FrameData->Errors, SizeToCopy);
++ ToPush.Errors=Buf;
+ }
+ Analysis[Analysis.size()-1]->push_back(ToPush);
+ }
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/dvanalyzer.git/commitdiff/a3be3189504002b7eda91e6db737c9cc0fbd1a5b
More information about the pld-cvs-commit
mailing list