From 388cf3374312b05122151bc68691bf09a69ff840 Mon Sep 17 00:00:00 2001 From: w0rp Date: Sat, 6 Feb 2021 20:13:28 +0000 Subject: Fix #3579 - Escape cppcheck arguments for Windows --- ale_linters/c/cppcheck.vim | 2 +- ale_linters/cpp/cppcheck.vim | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'ale_linters') diff --git a/ale_linters/c/cppcheck.vim b/ale_linters/c/cppcheck.vim index b671fc8b..975ef047 100644 --- a/ale_linters/c/cppcheck.vim +++ b/ale_linters/c/cppcheck.vim @@ -10,7 +10,7 @@ function! ale_linters#c#cppcheck#GetCommand(buffer) abort let l:buffer_path_include = empty(l:compile_commands_option) \ ? ale#handlers#cppcheck#GetBufferPathIncludeOptions(a:buffer) \ : '' - let l:template = ' --template=''{file}:{line}:{column}: {severity}:{inconclusive:inconclusive:} {message} [{id}]\\n{code}''' + let l:template = ' --template=' . ale#Escape('{file}:{line}:{column}: {severity}:{inconclusive:inconclusive:} {message} [{id}]\\n{code}') return l:cd_command \ . '%e -q --language=c' diff --git a/ale_linters/cpp/cppcheck.vim b/ale_linters/cpp/cppcheck.vim index 2c832246..2578861d 100644 --- a/ale_linters/cpp/cppcheck.vim +++ b/ale_linters/cpp/cppcheck.vim @@ -10,7 +10,7 @@ function! ale_linters#cpp#cppcheck#GetCommand(buffer) abort let l:buffer_path_include = empty(l:compile_commands_option) \ ? ale#handlers#cppcheck#GetBufferPathIncludeOptions(a:buffer) \ : '' - let l:template = ' --template=''{file}:{line}:{column}: {severity}:{inconclusive:inconclusive:} {message} [{id}]\\n{code}''' + let l:template = ' --template=' . ale#Escape('{file}:{line}:{column}: {severity}:{inconclusive:inconclusive:} {message} [{id}]\\n{code}') return l:cd_command \ . '%e -q --language=c++' -- cgit v1.2.3