diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/charset/detect.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/charset/detect.c b/src/charset/detect.c index 2612fa8..9f8da69 100644 --- a/src/charset/detect.c +++ b/src/charset/detect.c @@ -144,10 +144,8 @@ parserutils_error css_charset_read_bom_or_charset(const uint8_t *data, } error = try_ascii_compatible_charset(data, len, &charset); - if (error != PARSERUTILS_OK) - return error; - - *mibenum = charset; + if (error == PARSERUTILS_OK) + *mibenum = charset; return PARSERUTILS_OK; } |