[PATCH 11/13] Xming: Ensure we dont try to print a null value when displaying xkb configuration

Jon TURNEY jon.turney at dronecode.org.uk
Wed Jan 7 12:04:06 PST 2009


From: Colin Harrison <colin.harrison at virgin.net>

Signed-off-by: Jon TURNEY <jon.turney at dronecode.org.uk>
---
 hw/xwin/winkeybd.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/hw/xwin/winkeybd.c b/hw/xwin/winkeybd.c
index 90cd5af..24a7b43 100644
--- a/hw/xwin/winkeybd.c
+++ b/hw/xwin/winkeybd.c
@@ -267,9 +267,11 @@ winKeybdProc (DeviceIntPtr pDeviceInt, int iState)
 
 	  winErrorFVerb(2, "Rules = \"%s\" Model = \"%s\" Layout = \"%s\""
 		 " Variant = \"%s\" Options = \"%s\"\n",
-		 g_winInfo.xkb.rules, g_winInfo.xkb.model,
-		 g_winInfo.xkb.layout, g_winInfo.xkb.variant,
-		 g_winInfo.xkb.options);
+		 g_winInfo.xkb.rules ? g_winInfo.xkb.rules : "none",
+		 g_winInfo.xkb.model ? g_winInfo.xkb.model : "none",
+		 g_winInfo.xkb.layout ? g_winInfo.xkb.layout : "none",
+		 g_winInfo.xkb.variant ? g_winInfo.xkb.variant : "none",
+		 g_winInfo.xkb.options ? g_winInfo.xkb.options : "none");
           
 	  XkbSetRulesDflts (g_winInfo.xkb.rules, g_winInfo.xkb.model, 
 			    g_winInfo.xkb.layout, g_winInfo.xkb.variant, 
-- 
1.6.0.4




More information about the xorg mailing list