diff --git a/SOURCES/vim-7.4-yamlsyntax.patch b/SOURCES/vim-7.4-yamlsyntax.patch new file mode 100644 index 0000000..5a06fe6 --- /dev/null +++ b/SOURCES/vim-7.4-yamlsyntax.patch @@ -0,0 +1,22 @@ +diff -up vim74/runtime/syntax/yaml.vim.yamlsyntax vim74/runtime/syntax/yaml.vim +--- vim74/runtime/syntax/yaml.vim.yamlsyntax 2016-11-25 13:08:38.621772847 +0100 ++++ vim74/runtime/syntax/yaml.vim 2016-11-25 15:04:38.170017620 +0100 +@@ -103,14 +103,15 @@ execute 'syn match yamlPlainScalar conta + syn match yamlMappingKeyStart '?\ze\s' + syn match yamlMappingKeyStart '?' contained + +-execute 'syn match yamlFlowMappingKey /'.s:ns_plain_in.'\ze\s*:/ contained '. ++execute 'syn match yamlFlowMappingKey /\%#=1'.s:ns_plain_in.'\%(\s\+'.s:ns_plain_in.'\)*\ze\s*:/ contained '. + \'nextgroup=yamlKeyValueDelimiter' + syn match yamlFlowMappingMerge /<<\ze\s*:/ contained nextgroup=yamlKeyValueDelimiter + + syn match yamlBlockCollectionItemStart '^\s*\zs-\%(\s\+-\)*\s' nextgroup=yamlBlockMappingKey,yamlBlockMappingMerge +-execute 'syn match yamlBlockMappingKey /^\s*\zs'.s:ns_plain_out.'\ze\s*:\%(\s\|$\)/ '. ++" Use the old regexp engine, the NFA engine doesn't like all the \@ items. ++execute 'syn match yamlBlockMappingKey /\%#=1^\s*\zs'.s:ns_plain_out.'\%(\s\+'.s:ns_plain_out.'\)*\ze\s*:\%(\s\|$\)/ '. + \'nextgroup=yamlKeyValueDelimiter' +-execute 'syn match yamlBlockMappingKey /\s*\zs'.s:ns_plain_out.'\ze\s*:\%(\s\|$\)/ contained '. ++execute 'syn match yamlBlockMappingKey /\%#=1\s*\zs'.s:ns_plain_out.'\%(\s\+'.s:ns_plain_out.'\)*\ze\s*:\%(\s\|$\)/ contained '. + \'nextgroup=yamlKeyValueDelimiter' + syn match yamlBlockMappingMerge /^\s*\zs<<\ze:\%(\s\|$\)/ nextgroup=yamlKeyValueDelimiter + syn match yamlBlockMappingMerge /<<\ze\s*:\%(\s\|$\)/ nextgroup=yamlKeyValueDelimiter contained diff --git a/SPECS/vim.spec b/SPECS/vim.spec index 40eb4ce..3cc96c2 100644 --- a/SPECS/vim.spec +++ b/SPECS/vim.spec @@ -20,7 +20,7 @@ Summary: The VIM editor URL: http://www.vim.org/ Name: vim Version: %{baseversion}.%{patchlevel} -Release: 1%{?dist}.1 +Release: 2%{?dist} License: Vim Group: Applications/Editors Source0: ftp://ftp.vim.org/pub/vim/unix/vim-%{baseversion}.tar.bz2 @@ -221,6 +221,7 @@ Patch3012: vim-7.3-manpage-typo-668894-675480.patch Patch3013: vim-7.3-xsubpp-path.patch Patch3014: vim-manpagefixes-948566.patch Patch3015: vim-7.4-CVE-2016-1248.patch +Patch3016: vim-7.4-yamlsyntax.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel ncurses-devel gettext perl-devel @@ -535,6 +536,7 @@ perl -pi -e "s,bin/nawk,bin/awk,g" runtime/tools/mve.awk %endif %patch3014 -p1 %patch3015 -p1 +%patch3016 -p1 %build cp -f %{SOURCE5} . @@ -1018,6 +1020,9 @@ rm -rf %{buildroot} %{_datadir}/icons/hicolor/*/apps/* %changelog +* Fri Jan 20 2017 Zdenek Dohnal - 2:7.4.160-2 +- 1383902 - CPU spikes to 100% and timeouts observed in strace when opening yaml extensions using vim + * Mon Dec 12 2016 Karsten Hopp 7.4.160-1.1 - add fix for CVE-2016-1248