Restore message logic. No bump.
This commit is contained in:
parent
5df01d314e
commit
951ed381a3
|
@ -55,7 +55,6 @@ static Bool UpdateCount( TidyDocImpl* doc, TidyReportLevel level )
|
||||||
break;
|
break;
|
||||||
case TidyWarning:
|
case TidyWarning:
|
||||||
doc->warnings++;
|
doc->warnings++;
|
||||||
go = go && cfgBool( doc, TidyShowWarnings );
|
|
||||||
break;
|
break;
|
||||||
case TidyConfig:
|
case TidyConfig:
|
||||||
doc->optionErrors++;
|
doc->optionErrors++;
|
||||||
|
@ -215,7 +214,7 @@ static void messageOut( TidyMessageImpl *message )
|
||||||
void TY_(ReportNotice)(TidyDocImpl* doc, Node *element, Node *node, uint code)
|
void TY_(ReportNotice)(TidyDocImpl* doc, Node *element, Node *node, uint code)
|
||||||
{
|
{
|
||||||
TidyMessageImpl *message = NULL;
|
TidyMessageImpl *message = NULL;
|
||||||
TidyMessageImpl *message2 = NULL; /* extra, when TidyShowWarnings */
|
TidyMessageImpl *message2 = NULL;
|
||||||
Node* rpt = ( element ? element : node );
|
Node* rpt = ( element ? element : node );
|
||||||
char nodedesc[256] = { 0 };
|
char nodedesc[256] = { 0 };
|
||||||
char elemdesc[256] = { 0 };
|
char elemdesc[256] = { 0 };
|
||||||
|
@ -307,6 +306,7 @@ void TY_(ReportNotice)(TidyDocImpl* doc, Node *element, Node *node, uint code)
|
||||||
message = TY_(tidyMessageCreateWithNode)(doc, node, code, TidyWarning, nodedesc, extra_string );
|
message = TY_(tidyMessageCreateWithNode)(doc, node, code, TidyWarning, nodedesc, extra_string );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
||||||
case CUSTOM_TAG_DETECTED:
|
case CUSTOM_TAG_DETECTED:
|
||||||
TagToString(element, elemdesc, sizeof(elemdesc));
|
TagToString(element, elemdesc, sizeof(elemdesc));
|
||||||
|
|
||||||
|
@ -329,6 +329,7 @@ void TY_(ReportNotice)(TidyDocImpl* doc, Node *element, Node *node, uint code)
|
||||||
message = TY_(tidyMessageCreateWithNode)(doc, element, code, TidyInfo, elemdesc, tagtype );
|
message = TY_(tidyMessageCreateWithNode)(doc, element, code, TidyInfo, elemdesc, tagtype );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
||||||
case ELEMENT_VERS_MISMATCH_ERROR:
|
case ELEMENT_VERS_MISMATCH_ERROR:
|
||||||
versionEmitted = doc->lexer->versionEmitted;
|
versionEmitted = doc->lexer->versionEmitted;
|
||||||
declared = doc->lexer->doctype;
|
declared = doc->lexer->doctype;
|
||||||
|
@ -381,6 +382,9 @@ void TY_(ReportNotice)(TidyDocImpl* doc, Node *element, Node *node, uint code)
|
||||||
}
|
}
|
||||||
|
|
||||||
messageOut( message );
|
messageOut( message );
|
||||||
|
|
||||||
|
/* is TidyInfo, but only show it if we're showing warnings! */
|
||||||
|
if ( cfgBool(doc, TidyShowWarnings) == yes )
|
||||||
messageOut( message2 );
|
messageOut( message2 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue