multithread cruncher: only copy stats when picture->stats != NULL

BUG=webp:336

Change-Id: I6dfbbdcf61a6cb455f6cbf3dcd7f4c46578f42aa
This commit is contained in:
Pascal Massimino 2017-06-14 21:48:42 +02:00
parent f8c2ac15af
commit f1d5a397db

View File

@ -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.
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);