1 9452 padraigo --- /usr/tmp/clean/at-spi-1.7.12/registryd/deviceeventcontroller.c 2006-07-20 23:05:53.000000000 +0100 2 9681 padraig +++ at-spi-1.7.12/registryd/deviceeventcontroller.c 2006-11-07 09:53:03.284843000 +0000 3 9681 padraig @@ -458,6 +458,8 @@ 4 9681 padraig } 5 9681 padraig else 6 9681 padraig spi_dec_set_unlatch_pending (controller, mask_return); 7 9681 padraig + 8 9681 padraig + CORBA_free (e.any_data._value); 9 9681 padraig } 10 9681 padraig return TRUE; 11 9681 padraig } 12 9681 padraig @@ -473,6 +475,7 @@ 13 9452 padraigo int *x, int *y, gboolean *moved) 14 9452 padraigo { 15 9452 padraigo Accessibility_Event e; 16 9452 padraigo + Accessibility_EventDetails *details; 17 9452 padraigo CORBA_Environment ev; 18 9452 padraigo int win_x_return,win_y_return; 19 9452 padraigo unsigned int mask_return; 20 9681 padraig @@ -510,6 +513,8 @@ 21 9452 padraigo Accessibility_Registry_notifyEvent (BONOBO_OBJREF (controller->registry), 22 9452 padraigo &e, 23 9452 padraigo &ev); 24 9452 padraigo + details = e.any_data._value; 25 9452 padraigo + CORBA_free (details); 26 9452 padraigo e.type = "mouse:rel"; 27 9452 padraigo e.source = BONOBO_OBJREF (controller->registry->desktop); 28 9452 padraigo e.detail1 = *x - last_mouse_pos->x; 29 9681 padraig @@ -524,6 +529,8 @@ 30 9452 padraigo Accessibility_Registry_notifyEvent (BONOBO_OBJREF (controller->registry), 31 9452 padraigo &e, 32 9452 padraigo &ev); 33 9452 padraigo + details = e.any_data._value; 34 9452 padraigo + CORBA_free (details); 35 9452 padraigo *moved = True; 36 9452 padraigo } 37 9452 padraigo else 38 9681 padraig @@ -564,6 +571,7 @@ 39 9681 padraig Accessibility_Registry_notifyEvent (BONOBO_OBJREF (controller->registry), 40 9681 padraig &e, 41 9681 padraig &ev); 42 9681 padraig + CORBA_free (e.any_data._value); 43 9681 padraig } 44 9681 padraig 45 9681 padraig static gboolean 46 9681 padraig @@ -1083,6 +1091,7 @@ 47 9681 padraig Accessibility_Registry_notifyEvent (BONOBO_OBJREF (controller->registry), 48 9681 padraig &e, 49 9681 padraig &ev); 50 9681 padraig + CORBA_free (e.any_data._value); 51 9681 padraig } 52 9681 padraig 53 9681 padraig xkb_mod_unlatch_occurred = (xevent->type == ButtonPress || 54 9681 padraig @@ -2509,6 +2518,7 @@ 55 9681 padraig { 56 9681 padraig CORBA_Environment ev; 57 9681 padraig Accessibility_DeviceEvent key_event; 58 9681 padraig + gboolean ret; 59 9681 padraig 60 9681 padraig g_assert (event->type == KeyPress || event->type == KeyRelease); 61 9681 padraig 62 9681 padraig @@ -2520,7 +2530,9 @@ 63 9681 padraig spi_controller_update_key_grabs (controller, &key_event); 64 9681 padraig 65 9681 padraig /* relay to listeners, and decide whether to consume it or not */ 66 9681 padraig - return spi_controller_notify_keylisteners (controller, &key_event, CORBA_TRUE, &ev); 67 9681 padraig + ret = spi_controller_notify_keylisteners (controller, &key_event, CORBA_TRUE, &ev); 68 9681 padraig + CORBA_free(key_event.event_string); 69 9681 padraig + return ret; 70 9681 padraig } 71 9681 padraig 72 9681 padraig SpiDEController * 73 9681 padraig --- /usr/tmp/clean/at-spi-1.7.12/registryd/registry.c 2006-09-18 22:03:48.000000000 +0100 74 9681 padraig +++ at-spi-1.7.12/registryd/registry.c 2006-11-07 13:05:49.782164000 +0000 75 9681 padraig @@ -602,7 +602,7 @@ 76 9681 padraig CORBA_Environment *ev; 77 9681 padraig Bonobo_Unknown source; 78 9681 padraig EventTypeStruct etype; 79 9681 padraig - Accessibility_Event e_out; 80 9681 padraig + Accessibility_Event *e_out; 81 9681 padraig } NotifyContext; 82 9681 padraig 83 9681 padraig static SpiReEntrantContinue 84 9681 padraig @@ -634,12 +634,12 @@ 85 9681 padraig } 86 9681 padraig #endif 87 9681 padraig 88 9681 padraig - ctx->e_out.source = ctx->source; 89 9681 padraig + ctx->e_out->source = ctx->source; 90 9681 padraig 91 9681 padraig if ((*list) && (*list)->data == ls) 92 9681 padraig { 93 9681 padraig Accessibility_EventListener_notifyEvent ( 94 9681 padraig - (Accessibility_EventListener) ls->listener, &ctx->e_out, ctx->ev); 95 9681 padraig + (Accessibility_EventListener) ls->listener, ctx->e_out, ctx->ev); 96 9681 padraig if (ctx->ev->_major != CORBA_NO_EXCEPTION) 97 9681 padraig { 98 9681 padraig DBG (1, g_warning ("Accessibility app error: exception during " 99 9681 padraig @@ -679,11 +679,7 @@ 100 9681 padraig new_ctx->etype.major = ctx->etype.major; 101 9681 padraig new_ctx->etype.minor = ctx->etype.minor; 102 9681 padraig new_ctx->etype.detail = ctx->etype.detail; 103 9681 padraig - new_ctx->e_out.type = CORBA_string_dup (ctx->e_out.type); 104 9681 padraig - new_ctx->e_out.source = ctx->e_out.source; 105 9681 padraig - new_ctx->e_out.detail1 = ctx->e_out.detail1; 106 9681 padraig - new_ctx->e_out.detail2 = ctx->e_out.detail2; 107 9681 padraig - CORBA_any__copy (&(new_ctx->e_out.any_data), &(ctx->e_out.any_data)); 108 9681 padraig + new_ctx->e_out = ORBit_copy_value (ctx->e_out, TC_Accessibility_Event); 109 9681 padraig return new_ctx; 110 9681 padraig } 111 9681 padraig 112 9681 padraig @@ -717,9 +713,7 @@ 113 9681 padraig bonobo_object_release_unref (q_ctx->source, NULL); 114 9681 padraig } 115 9681 padraig CORBA_free ((void *)q_ctx->etype.event_name); 116 9681 padraig - CORBA_free ((void *)q_ctx->e_out.type); 117 9681 padraig - if (q_ctx->e_out.any_data._type != TC_null) 118 9681 padraig - CORBA_free ((void *)q_ctx->e_out.any_data._value); 119 9681 padraig + CORBA_free (q_ctx->e_out); 120 9681 padraig g_free (q_ctx); 121 9681 padraig } 122 9681 padraig registry->is_queueing = FALSE; 123 9681 padraig @@ -834,25 +828,20 @@ 124 9681 padraig static gboolean 125 9681 padraig registry_queue_event (SpiRegistry *registry, NotifyContext *ctx) 126 9681 padraig { 127 9681 padraig - NotifyContext *q_ctx = registry_clone_notify_context (ctx); 128 9681 padraig #ifdef SPI_QUEUE_DEBUG 129 9681 padraig - if (q_ctx->etype.type_cat != ETYPE_MOUSE) 130 9681 padraig - fprintf (stderr, "push! %s %p\n", q_ctx->etype.event_name, q_ctx); 131 9681 padraig + if (ctx->etype.type_cat != ETYPE_MOUSE) 132 9681 padraig + fprintf (stderr, "push! %s %p\n", ctx->etype.event_name, ctx); 133 9681 padraig #endif 134 9681 padraig if (registry->is_queueing) 135 9681 padraig { 136 9681 padraig + NotifyContext *q_ctx = registry_clone_notify_context (ctx); 137 9681 padraig + 138 9681 padraig g_queue_push_head (registry->deferred_event_queue, q_ctx); 139 9681 padraig 140 9681 padraig return FALSE; 141 9681 padraig } 142 9681 padraig else 143 9681 padraig { 144 9681 padraig - bonobo_object_release_unref (q_ctx->source, NULL); 145 9681 padraig - CORBA_free ((void *)q_ctx->etype.event_name); 146 9681 padraig - CORBA_free ((void *)q_ctx->e_out.type); 147 9681 padraig - if (q_ctx->e_out.any_data._type != TC_null) 148 9681 padraig - CORBA_free ((void *)q_ctx->e_out.any_data._value); 149 9681 padraig - g_free (q_ctx); 150 9681 padraig return TRUE; 151 9681 padraig } 152 9681 padraig } 153 9681 padraig @@ -917,7 +906,7 @@ 154 9681 padraig parse_event_type (&ctx.etype, e->type); 155 9681 padraig 156 9681 padraig ctx.ev = ev; 157 9681 padraig - ctx.e_out = *e; 158 9681 padraig + ctx.e_out = (Accessibility_Event *)e; 159 9681 padraig ctx.source = e->source; 160 9681 padraig 161 9681 padraig #ifdef SPI_QUEUE_DEBUG 162