mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-21 10:55:51 +02:00
lavc/libx264.c: Fix possible UB by NULL pointer LHS
It is UB to attempt to do pointer arithmetic on NULL pointer LHS, even if that pointer arithmetic ends up being "+= 0" (i.e. !!p == 0 if p == NULL).
This commit is contained in:
parent
6c3a82f043
commit
0aa5dd084b
@ -940,7 +940,9 @@ static av_cold int X264_init(AVCodecContext *avctx)
|
||||
return ret;
|
||||
}
|
||||
p= strchr(p, ':');
|
||||
p+=!!p;
|
||||
if (p) {
|
||||
++p;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user