diff --git a/src/enc/vp8l_enc.c b/src/enc/vp8l_enc.c index 56f82d52..0877f0af 100644 --- a/src/enc/vp8l_enc.c +++ b/src/enc/vp8l_enc.c @@ -1796,7 +1796,9 @@ WebPEncodingError VP8LEncodeStream(const WebPConfig* const config, } // This line is here and not in the param initialization above to remove a // Clang static analyzer warning. - memcpy(&stats_side, picture->stats, sizeof(stats_side)); + if (picture->stats != NULL) { + memcpy(&stats_side, picture->stats, sizeof(stats_side)); + } // This line is only useful to remove a Clang static analyzer warning. params_side.err_ = VP8_ENC_OK; worker_interface->Launch(&worker_side);