test: fix test script to use the new API and get rid of build warning.

This commit is contained in:
Jehan 2020-04-23 16:43:56 +02:00
parent 7bc1bc4e0a
commit e7bf25ca08

View File

@ -67,7 +67,7 @@ detect(FILE *fp)
} }
uchardet_data_end(handle); uchardet_data_end(handle);
charset = strdup(uchardet_get_charset(handle)); charset = strdup(uchardet_get_encoding(handle, 0));
for (i = 0; charset[i]; i++) for (i = 0; charset[i]; i++)
{ {
/* Our test files are lowercase. */ /* Our test files are lowercase. */