OSDN Git Service

tests: Only copy con->modes[0] if it exists
authorMichel Dänzer <mdaenzer@redhat.com>
Thu, 27 Feb 2020 11:21:09 +0000 (12:21 +0100)
committerMichel Dänzer <michel@daenzer.net>
Thu, 27 Feb 2020 11:21:09 +0000 (12:21 +0100)
commitfe06ee2054ac8aa609f64d2cdfad294a5e3d5610
tree4f8fa6f5467d96fce21ef5ad326fd45fd06f7d24
parent8a73372e62a73fe8d874aa39458c508cdb5bb6f4
tests: Only copy con->modes[0] if it exists

con->modes can be NULL. Fixes crash in that case.

Closes: https://gitlab.freedesktop.org/mesa/drm/issues/34
Reviewed-by: Daniel Stone <daniels@collabora.com>
tests/kms/libkms-test-screen.c