Correctly use a copy of args so both filters can work.
This commit is contained in:
parent
5786a5afb5
commit
f3cc89d234
|
@ -1028,6 +1028,8 @@ static void messagePos( TidyDocImpl* doc, TidyReportLevel level,
|
||||||
|
|
||||||
if ( go )
|
if ( go )
|
||||||
{
|
{
|
||||||
|
va_list args_copy;
|
||||||
|
va_copy(args_copy, args);
|
||||||
TY_(tmbvsnprintf)(messageBuf, sizeMessageBuf, msg, args);
|
TY_(tmbvsnprintf)(messageBuf, sizeMessageBuf, msg, args);
|
||||||
if ( doc->mssgFilt )
|
if ( doc->mssgFilt )
|
||||||
{
|
{
|
||||||
|
@ -1037,7 +1039,7 @@ static void messagePos( TidyDocImpl* doc, TidyReportLevel level,
|
||||||
if ( doc->mssgFilt2 )
|
if ( doc->mssgFilt2 )
|
||||||
{
|
{
|
||||||
TidyDoc tdoc = tidyImplToDoc( doc );
|
TidyDoc tdoc = tidyImplToDoc( doc );
|
||||||
go = doc->mssgFilt2( tdoc, level, line, col, msg, args );
|
go = doc->mssgFilt2( tdoc, level, line, col, msg, args_copy );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue