summaryrefslogtreecommitdiff
path: root/hw/kdrive/src/vga.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2003-10-14 05:07:39 +0000
committerKeith Packard <keithp@keithp.com>2003-10-14 05:07:39 +0000
commit4b844cafb2516139c8407822b61939cd6c743742 (patch)
tree0e1232bbf30f353aeec8567288f89b02f2aee582 /hw/kdrive/src/vga.c
parentcdf3377f6d3789628495ac64df80ac7dc235e46d (diff)
Check for off-screen pixmap support in KaaDrawableIsOffscreenPixmap. -Wall
fixes. Allocate pixmap private space only for screens with off-screen pixmap support
Diffstat (limited to 'hw/kdrive/src/vga.c')
-rw-r--r--hw/kdrive/src/vga.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/kdrive/src/vga.c b/hw/kdrive/src/vga.c
index 06b5d92b8..23372424c 100644
--- a/hw/kdrive/src/vga.c
+++ b/hw/kdrive/src/vga.c
@@ -93,7 +93,7 @@ VGA8
VgaFetch (VgaCard *card, VGA16 reg)
{
VgaMap map;
- VGA8 value;
+ VGA8 value = 0;
(*card->map) (card, reg, &map, VGAFALSE);
switch (map.access) {
@@ -235,7 +235,7 @@ VgaSet (VgaCard *card, VgaReg *reg, VGA32 value)
mask <<= reg->base;
new <<= reg->base;
v = card->values[reg->id].cur;
- v = v & ~mask | new;
+ v = (v & ~mask) | new;
card->values[reg->id].cur = v;
card->values[reg->id].flags |= VGA_VALUE_MODIFIED|VGA_VALUE_DIRTY;
}