Bugfix for keylistener problem.
authorbillh <billh@e2bd861d-eb25-0410-b326-f6ed22b6b98c>
Thu, 9 May 2002 17:21:53 +0000 (17:21 +0000)
committerbillh <billh@e2bd861d-eb25-0410-b326-f6ed22b6b98c>
Thu, 9 May 2002 17:21:53 +0000 (17:21 +0000)
git-svn-id: http://svn.gnome.org/svn/at-spi/trunk@292 e2bd861d-eb25-0410-b326-f6ed22b6b98c

ChangeLog
cspi/spi_registry.c

index 17b24e3..a567314 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2002-05-09  Bill Haneman <bill.haneman@sun.com>
 
+       * cspi/spi_registry.c:
+       Fixed nasty bug in SPI_registerAccessibleKeystrokeListener
+       which was uncovered by the recent key changes.
+
+2002-05-09  Bill Haneman <bill.haneman@sun.com>
+
        * test/event-listener-test.c:
        * test/Makefile.am:
        Added new test, "event-listener-test"; 
index bb7e3c3..95abd2b 100644 (file)
@@ -348,8 +348,14 @@ SPI_registerAccessibleKeystrokeListener (AccessibleKeystrokeListener  *listener,
         {
           key_set._buffer[i].keycode = keys->keycodes[i];
          key_set._buffer[i].keysym = keys->keysyms[i];
-         key_set._buffer[i].keystring = (keys->keystrings[i] != NULL) ?
-                 keys->keystrings[i] : CORBA_string_dup("");
+         if (keys->keystrings && keys->keystrings[i]) 
+           {
+             key_set._buffer[i].keystring = keys->keystrings[i];
+           } 
+          else 
+            {
+             key_set._buffer[i].keystring = CORBA_string_dup("");
+           }
         }
     }
   else