[at-spi2-core: 28/32] spi_dec_plat_get_keycode(): don't leave modmask uninitialized




commit 797c9767ee04301a97fe92e4a43d572bd43e2f30
Author: Federico Mena Quintero <federico gnome org>
Date:   Tue Dec 14 16:06:08 2021 -0600

    spi_dec_plat_get_keycode(): don't leave modmask uninitialized

 registryd/deviceeventcontroller.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
---
diff --git a/registryd/deviceeventcontroller.c b/registryd/deviceeventcontroller.c
index f6dea5b4..b5390b87 100644
--- a/registryd/deviceeventcontroller.c
+++ b/registryd/deviceeventcontroller.c
@@ -122,7 +122,13 @@ spi_dec_plat_get_keycode (SpiDEController *controller,
   if (klass->plat.get_keycode)
     return klass->plat.get_keycode (controller, keysym, key_str, fix, modmask);
   else
-    return keysym;
+    {
+      if (modmask)
+        {
+          *modmask = 0;
+        }
+      return keysym;
+    }
 }
 
 static guint


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