diff options
author | Łukasz Spintzyk <lukasz.spintzyk@synaptics.com> | 2021-06-23 15:26:23 +0200 |
---|---|---|
committer | Łukasz Spintzyk <lukasz.spintzyk@synaptics.com> | 2021-06-24 09:05:57 +0200 |
commit | d66b7ec12986efd4f32fcc84cdaacbd04ec98ccb (patch) | |
tree | c20827357b5b4d1ca9232f8fde9f303e53dee714 /hw | |
parent | 0d93bbfa2cfacbb73741f8bed0e32fa1a656b928 (diff) |
xfree86: Fix out of array bound access to xf86Entities
Signed-off-by: Łukasz Spintzyk <lukasz.spintzyk@synaptics.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/xfree86/common/xf86Bus.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/xfree86/common/xf86Bus.c b/hw/xfree86/common/xf86Bus.c index 272ad4cbe..8a7fc4327 100644 --- a/hw/xfree86/common/xf86Bus.c +++ b/hw/xfree86/common/xf86Bus.c @@ -528,8 +528,8 @@ xf86GetDevFromEntity(int entityIndex, int instance) for (i = 0; i < xf86Entities[entityIndex]->numInstances; i++) if (xf86Entities[entityIndex]->devices[i]->screen == instance) - break; - return xf86Entities[entityIndex]->devices[i]; + return xf86Entities[entityIndex]->devices[i]; + return NULL; } /* |