summaryrefslogtreecommitdiff
path: root/tests/kms-test-legacy-modeset.py
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2022-07-31 17:56:24 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2022-07-31 18:15:43 +0300
commit96082f398145757ef092ef19af53f12666b69552 (patch)
tree3e72630155a3d3a3394289a607eaecf658fc309f /tests/kms-test-legacy-modeset.py
parentb4da7b2eacdfa8e4a88cbe190d79a0cb11f82b92 (diff)
kmstest: Fix exception handling in CRCReader constructor and destructor
If an exception occurs in the CRCReader constructor, the self.dir, self.ctrl and self.data members may not be set. This causes another exception to be thrown by the destructor when it tries to access those members. Fix it by initializing all the members first, and only closing the dir and ctrl file descriptors if they have been successfully opened. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'tests/kms-test-legacy-modeset.py')
0 files changed, 0 insertions, 0 deletions