winex11.drv: use consistent formatting in a TRACE()

Austin English austinenglish at gmail.com
Tue Jan 4 20:42:49 CST 2011


I found it because clang warns about it:
keyboard.c:1300:36: warning: flag '#' results in undefined behavior
with 'X' conversion specifier [-Wformat]
        TRACE("Adjusting state for vkey %#.2X. State before %#.2x\n",
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

while technically, it is a clang bug:
http://llvm.org/bugs/show_bug.cgi?id=8641 (that has been fixed
already), the rest of the file uses %#.2x, so may as well make it
consistent.

-- 
-Austin
-------------- next part --------------
diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c
index d6054d6..313ff3a 100644
--- a/dlls/winex11.drv/keyboard.c
+++ b/dlls/winex11.drv/keyboard.c
@@ -1297,7 +1297,7 @@ static inline void KEYBOARD_UpdateOneState ( WORD vkey, WORD scan, int state, DW
 
         if (!state) flags |= KEYEVENTF_KEYUP;
 
-        TRACE("Adjusting state for vkey %#.2X. State before %#.2x\n",
+        TRACE("Adjusting state for vkey %#.2x. State before %#.2x\n",
               vkey, key_state_table[vkey & 0xff]);
 
         /* Fake key being pressed inside wine */


More information about the wine-patches mailing list