diff --git a/fix-memleak-in-GetTokenFromStream.patch b/fix-memleak-in-GetTokenFromStream.patch deleted file mode 100644 index d0bbef0..0000000 --- a/fix-memleak-in-GetTokenFromStream.patch +++ /dev/null @@ -1,40 +0,0 @@ -From 4377ab84a4a2748d72be91d26210567cc933c760 Mon Sep 17 00:00:00 2001 -From: lutianxiong -Date: Sat, 20 Jun 2020 09:19:17 +0800 -Subject: [PATCH 095/109] fix memleak in GetTokenFromStream - -check asp & php if ParseAttribute return NULL ---- - src/lexer.c | 16 ++++++++++++++++ - 1 file changed, 16 insertions(+) - -diff --git a/src/lexer.c b/src/lexer.c -index ca66aee..bbc1e15 100644 ---- a/src/lexer.c -+++ b/src/lexer.c -@@ -3263,6 +3263,22 @@ static Node* GetTokenFromStream( TidyDocImpl* doc, GetTokenMode mode ) - - if (!name) - { -+ /* check if attributes are created by ASP markup */ -+ if (asp) -+ { -+ av = TY_(NewAttribute)(doc); -+ av->asp = asp; -+ AddAttrToList( &attributes, av ); -+ } -+ -+ /* check if attributes are created by PHP markup */ -+ if (php) -+ { -+ av = TY_(NewAttribute)(doc); -+ av->php = php; -+ AddAttrToList( &attributes, av ); -+ } -+ - /* fix for http://tidy.sf.net/bug/788031 */ - lexer->lexsize -= 1; - lexer->txtend = lexer->txtstart; --- -1.8.3.1 - diff --git a/free-attributes-before-return-NULL.patch b/free-attributes-before-return-NULL.patch deleted file mode 100644 index 945c2c7..0000000 --- a/free-attributes-before-return-NULL.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 8f0e7aa22a854add9e6082ca5136e82f032a236a Mon Sep 17 00:00:00 2001 -From: lutianxiong -Date: Sun, 22 Nov 2020 00:10:12 +0800 -Subject: [PATCH] Free attributes before return NULL (#899) - ---- - src/lexer.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/src/lexer.c b/src/lexer.c -index 49b74f5..16a8fef 100644 ---- a/src/lexer.c -+++ b/src/lexer.c -@@ -3469,6 +3469,10 @@ static Node* GetTokenFromStream( TidyDocImpl* doc, GetTokenMode mode ) - return node; /* the COMMENT token */ - } - -+ /* check attributes before return NULL */ -+ if (attributes) -+ TY_(FreeAttribute)( doc, attributes ); -+ - DEBUG_LOG(SPRTF("Returning NULL...\n")); - return NULL; - } --- -1.8.3.1 - diff --git a/tidy-html5-5.7.28.tar.gz b/tidy-html5-5.7.28.tar.gz deleted file mode 100644 index 1516b97..0000000 Binary files a/tidy-html5-5.7.28.tar.gz and /dev/null differ diff --git a/tidy-html5-5.8.0.tar.gz b/tidy-html5-5.8.0.tar.gz new file mode 100644 index 0000000..ebb75ed Binary files /dev/null and b/tidy-html5-5.8.0.tar.gz differ diff --git a/tidy.spec b/tidy.spec index b5ccc71..2c2b2e7 100644 --- a/tidy.spec +++ b/tidy.spec @@ -2,15 +2,12 @@ %global upname tidy-html5 Name: tidy -Version: 5.7.28 +Version: 5.8.0 Release: 1 Summary: Utility to clean up and pretty print HTML/XHTML/XML License: W3C URL: http://www.html-tidy.org/ -Source0: https://github.com/htacg/%{upname}/archive/%{version}.tar.gz#/%{upname}-%{version}.tar.gz - -Patch0: fix-memleak-in-GetTokenFromStream.patch -Patch1: free-attributes-before-return-NULL.patch +Source0: https://github.com/htacg/%{upname}/archive/%{version}/%{upname}-%{version}.tar.gz BuildRequires: gcc-c++ cmake gcc libxslt pkgconfig Provides: tidy-html5 = %{version}-%{release} @@ -81,6 +78,9 @@ ln -s tidyplatform.h $RPM_BUILD_ROOT%{_includedir}/platform.h %{_mandir}/* %changelog +* Tue Oct 17 2023 xu_ping <707078654@qq.com> - 5.8.0-1 +- Update to version 5.8.0 + * Tue Jan 26 2021 fuanan - 5.7.28-1 - Update to version 5.7.28