Skip to content

Commit

Permalink
avcodec/dvdsubdec: use avpriv_fopen_utf8() instead of plain fopen()
Browse files Browse the repository at this point in the history
Unify file access operations by replacing usages of direct calls
to posix fopen() to prepare for long filename support on Windows.

Signed-off-by: softworkz <softworkz@hotmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
  • Loading branch information
softworkz authored and mstorsjo committed May 24, 2022
1 parent f579a1d commit 6b32ad5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libavcodec/dvdsubdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ static int parse_ifo_palette(DVDSubContext *ctx, char *p)
const uint8_t *cm = ff_crop_tab + MAX_NEG_CROP;

ctx->has_palette = 0;
if ((ifo = fopen(p, "r")) == NULL) {
if ((ifo = avpriv_fopen_utf8(p, "r")) == NULL) {
av_log(ctx, AV_LOG_WARNING, "Unable to open IFO file \"%s\": %s\n", p, av_err2str(AVERROR(errno)));
return AVERROR_EOF;
}
Expand Down

0 comments on commit 6b32ad5

Please sign in to comment.