Skip to contentSkip to conversation

console: Fix qemu_default_pixelformat() for 24 bpp

PATCH Applied Markus Armbruster 3 participants 3 messages Nov 22, 2011 – Nov 23, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 console: Fix qemu_default_pixelformat() for 24 bpp

Falls through to 32 bpp. Harmless, because the only difference is the alpha component, and we're not using that. Spotted by Coverity.

---
 console.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
console.c +1 -0
index ce0429d..223f8fd 100644
@@ -1688,6 +1688,7 @@ PixelFormat qemu_default_pixelformat(int bpp)
             pf.rbits = 8;
             pf.gbits = 8;
             pf.bbits = 8;
+            break;
         case 32:
             pf.rmask = 0x00FF0000;
             pf.gmask = 0x0000FF00;
Signature · 1 line
1.7.6.4
#1 lore raw
Quoted 4 lines · Markus Armbruster

Falls through to 32 bpp. Harmless, because the only difference is the alpha component, and we're not using that. Spotted by Coverity.

ack

Quoted 19 lines
 console.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
console.c +1 -0
index ce0429d..223f8fd 100644
@@ -1688,6 +1688,7 @@ PixelFormat qemu_default_pixelformat(int bpp)
             pf.rbits = 8;
             pf.gbits = 8;
             pf.bbits = 8;
+            break;
         case 32:
             pf.rmask = 0x00FF0000;
             pf.gmask = 0x0000FF00;
Signature · 1 line
1.7.6.4
#2 lore raw
In reply to Markus Armbruster
Quoted 7 lines · Markus Armbruster

Falls through to 32 bpp. Harmless, because the only difference is the alpha component, and we're not using that. Spotted by Coverity.

---
 console.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Thanks, applied to the trivial patches -next tree:
http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/trivial-patches-next

Stefan