zink: zero out zink_render_pass_state
authorDuncan Hopkins <duncan@thefoundry.co.uk>
Thu, 12 Mar 2020 16:45:39 +0000 (16:45 +0000)
committerMarge Bot <eric+marge@anholt.net>
Tue, 17 Mar 2020 13:04:30 +0000 (13:04 +0000)
commit4c35bc7e612f806d2e8a8a7126ddcdf45597806a
treebe605d1d0732a257b49237d403e85e52c485f47f
parentc923de68dd0ab10a5a5fb3196f539707d046d897
zink: zero out zink_render_pass_state

Since zink_render_pass_state is used as a hash-key, the entire struct gets
compared. This means we don't want any uninitialized padding in there, or
else we risk getting false negatives. This has led to issues on macOS builds.

So let's zero out the struct before we start filling it out.

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4212>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4212>
src/gallium/drivers/zink/zink_context.c