@@ -2210,6 +2210,7 @@ void FixBrakes( TidyDocImpl* pDoc, Node *pParent )
2210
2210
2211
2211
/* Issue #456 - This is discarded
2212
2212
See replacement TidyMetaCharset */
2213
+ #if 0 /* 000000000000000000000000 */
2213
2214
void TY_ (VerifyHTTPEquiv )(TidyDocImpl * doc , Node * head )
2214
2215
{
2215
2216
Node * pNode ;
@@ -2285,6 +2286,7 @@ void TY_(VerifyHTTPEquiv)(TidyDocImpl* doc, Node *head)
2285
2286
pLastProp = NULL ;
2286
2287
}
2287
2288
}
2289
+ #endif /* 000000000000000000000000 */
2288
2290
2289
2291
/*\
2290
2292
* Issue #456 - Check meta charset
@@ -2324,10 +2326,12 @@ Bool TY_(TidyMetaCharset)(TidyDocImpl* doc)
2324
2326
if (cfgAutoBool (doc , TidyBodyOnly ) == TidyYesState )
2325
2327
return no ; /* nothing to do here if showing body only */
2326
2328
2329
+ #if 0 /* 000000000000000000000000 */
2327
2330
if (!add_meta ) {
2328
2331
TY_ (VerifyHTTPEquiv )(doc , head );
2329
2332
return no ;
2330
2333
}
2334
+ #endif /* 000000000000000000000000 */
2331
2335
2332
2336
tidyBufInit (& charsetString );
2333
2337
/* Set up the content test 'charset=value' */
@@ -2419,7 +2423,7 @@ Bool TY_(TidyMetaCharset)(TidyDocImpl* doc)
2419
2423
in void TY_(VerifyHTTPEquiv)(TidyDocImpl* doc, Node *head)
2420
2424
lcontent = TY_(tmbstrtolower)(contentAttr->value);
2421
2425
*/
2422
- if (TY_ (tmbstrcasecmp )(contentAttr -> value , charsetString .bp ))
2426
+ if (TY_ (tmbstrcasecmp )(contentAttr -> value , charsetString .bp ) == 0 )
2423
2427
{
2424
2428
/* we already found one, so remove the rest. */
2425
2429
if (charsetFound )
@@ -2470,7 +2474,7 @@ Bool TY_(TidyMetaCharset)(TidyDocImpl* doc)
2470
2474
}
2471
2475
2472
2476
/* completed head scan - add appropriate meta - if 'yes' and none exists */
2473
- if (cfgBool ( doc , TidyMetaCharset ) && !charsetFound )
2477
+ if (add_meta && !charsetFound )
2474
2478
{
2475
2479
/* add appropriate meta charset tag - no warning */
2476
2480
metaTag = TY_ (InferredTag )(doc , TidyTag_META );
0 commit comments