mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avutil/avsscanf: fix possible overreads when dealing with %c or %s
This commit is contained in:
parent
b0298ad4e5
commit
13df9bfbcb
@ -113,7 +113,7 @@ static int ffshgetc(FFFILE *f)
|
||||
}
|
||||
|
||||
#define shlim(f, lim) ffshlim((f), (lim))
|
||||
#define shgetc(f) (((f)->rpos != (f)->shend) ? *(f)->rpos++ : ffshgetc(f))
|
||||
#define shgetc(f) (((f)->rpos < (f)->shend) ? *(f)->rpos++ : ffshgetc(f))
|
||||
#define shunget(f) ((f)->shend ? (void)(f)->rpos-- : (void)0)
|
||||
|
||||
static const unsigned char table[] = { -1,
|
||||
|
Loading…
Reference in New Issue
Block a user