mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-11-17 06:48:33 +00:00
[libvpx] scan-build: avoid dereference of null pointer
This commit is contained in:
1 parent
b9b0b00912
commit
1499acac9d
1 file changed
+2
@@ -299,6 +299,8 @@ static INLINE int get_free_fb(VP9_COMMON *cm) {
|
|||||||
static INLINE void ref_cnt_fb(RefCntBuffer *bufs, int *idx, int new_idx) {
|
static INLINE void ref_cnt_fb(RefCntBuffer *bufs, int *idx, int new_idx) {
|
||||||
const int ref_index = *idx;
|
const int ref_index = *idx;
|
||||||
|
|
||||||
|
if (!bufs) return;
|
||||||
|
|
||||||
if (ref_index >= 0 && bufs[ref_index].ref_count > 0)
|
if (ref_index >= 0 && bufs[ref_index].ref_count > 0)
|
||||||
bufs[ref_index].ref_count--;
|
bufs[ref_index].ref_count--;
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user