Merge "video: adf: zero out mapping data on adf_buffer_map() failure"

This commit is contained in:
Linux Build Service Account 2016-09-10 06:39:11 -07:00 committed by Gerrit - the friendly Code Review server
commit 1acb54a652

View file

@ -305,8 +305,10 @@ static int adf_buffer_map(struct adf_device *dev, struct adf_buffer *buf,
} }
done: done:
if (ret < 0) if (ret < 0) {
adf_buffer_mapping_cleanup(mapping, buf); adf_buffer_mapping_cleanup(mapping, buf);
memset(mapping, 0, sizeof(*mapping));
}
return ret; return ret;
} }