qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 5/5] vmware-vga: use vmsvga_verify_rect in vmsvga_fi


From: Gerd Hoffmann
Subject: [Qemu-devel] [PATCH 5/5] vmware-vga: use vmsvga_verify_rect in vmsvga_fill_rect
Date: Tue, 14 Oct 2014 09:45:10 +0200

Add verification to vmsvga_fill_rect, re-enable HW_FILL_ACCEL.

Cc: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>
---
 hw/display/vmware_vga.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/hw/display/vmware_vga.c b/hw/display/vmware_vga.c
index d29470b..a52346c 100644
--- a/hw/display/vmware_vga.c
+++ b/hw/display/vmware_vga.c
@@ -30,9 +30,7 @@
 
 #undef VERBOSE
 #define HW_RECT_ACCEL
-#if 0
 #define HW_FILL_ACCEL
-#endif
 #define HW_MOUSE_ACCEL
 
 #include "vga_int.h"
@@ -452,6 +450,10 @@ static inline void vmsvga_fill_rect(struct vmsvga_state_s 
*s,
     uint8_t *src;
     uint8_t col[4];
 
+    if (!vmsvga_verify_rect(surface, __func__, x, y, w, h)) {
+        return;
+    }
+
     col[0] = c;
     col[1] = c >> 8;
     col[2] = c >> 16;
-- 
1.8.3.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]