diff --git a/0001-fix-panic-while-use-special-string.patch b/0001-fix-panic-while-use-special-string.patch new file mode 100644 index 0000000000000000000000000000000000000000..7ed38d874105174bc245304b776bd7b25265b263 --- /dev/null +++ b/0001-fix-panic-while-use-special-string.patch @@ -0,0 +1,71 @@ +From 96e957e379485113afa7c48c03b190b5413a0c41 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?=E8=83=A1=E4=B8=81=E6=B4=8B10346053?= + +Date: Fri, 23 May 2025 10:40:09 +0800 +Subject: [PATCH] fix panic while use special string + +--- + orc/orcparse.c | 6 +++--- + orc/orcparse.h | 2 +- + tools/orcc.c | 2 +- + 3 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/orc/orcparse.c b/orc/orcparse.c +index abeb9f5..a0e4daf 100644 +--- a/orc/orcparse.c ++++ b/orc/orcparse.c +@@ -311,7 +311,7 @@ orc_line_parse_tokens (OrcLine *line) + { + while (line->p < line->end) { + orc_line_skip_blanks (line); +- if (!orc_line_has_data (line) || orc_line_is_comment (line)) { ++ if (line->n_tokens >= ORC_LINE_MAX_TOKENS || !orc_line_has_data (line) || orc_line_is_comment (line)) { + break; + } + orc_line_add_token (line); +@@ -370,14 +370,14 @@ orc_parse_splat_error (OrcParseError **errors, int n_errors, char **log) + } + + void +-orc_parse_error_freev(OrcParseError **errors) ++orc_parse_error_freev(OrcParseError **errors,int n_errors) + { + int i; + + if (errors == NULL) + return; + +- for (i=0;errors[i]!=NULL;i++) { ++ for (i=0;isource, errors[i]->line_number, errors[i]->text); + } +- orc_parse_error_freev (errors); ++ orc_parse_error_freev (errors, n_errors); + exit (1); + } + +-- +2.27.0 + diff --git a/orc.spec b/orc.spec index f7f6bc137456aa549611242b6b15f584ab39ff89..ff06d6249ee5571e0aded90a89472f552372e496 100644 --- a/orc.spec +++ b/orc.spec @@ -8,6 +8,7 @@ Summary: The Oil Run-time Compiler License: BSD URL: https://gstreamer.freedesktop.org/ Source0: https://gstreamer.freedesktop.org/src/orc/%{name}-%{version}.tar.xz +Patch0: 0001-fix-panic-while-use-special-string.patch BuildRequires: meson >= 0.55.0 BuildRequires: gcc @@ -88,6 +89,10 @@ rm -rf %{buildroot}/%{_libdir}/orc %{abidir}/orcc-option.list %changelog +* Fri May 23 2025 Hu Dingyang - 0.4.39-2 +- Add 0001-fix-panic-while-use-special-string.patch +- Fix panic when using special strings + * Thu Feb 27 2025 Xiaoping Liu - 0.4.39-1 - update to 0.4.39 from 0.4.33 - Fix CVE-2024-40897