diff --git a/libavcodec/htmlsubtitles.c b/libavcodec/htmlsubtitles.c
index d9221ba16b..8ce66e0b27 100644
--- a/libavcodec/htmlsubtitles.c
+++ b/libavcodec/htmlsubtitles.c
@@ -55,7 +55,7 @@ static int scanbraces(const char* in) {
if (strncmp(in, "{\\an", 4) != 0) {
return 0;
}
- if (!isdigit(in[4])) {
+ if (!av_isdigit(in[4])) {
return 0;
}
if (in[5] != '}') {