1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-10-06 02:05:36 +02:00

ass_split_section: dont overread array

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2012-12-14 18:10:19 +01:00
parent b2c2589ecf
commit 6ca2465556

View File

@ -267,7 +267,8 @@ static const char *ass_split_section(ASSSplitContext *ctx, const char *buf)
} }
} }
} }
buf += strcspn(buf, "\n") + 1; buf += strcspn(buf, "\n");
buf += !!*buf;
} }
return buf; return buf;
} }