Skip to content

Commit

Permalink
CELIX-350: Fixes wrong handling of shell service refernce in the shel…
Browse files Browse the repository at this point in the history
…l_tui
  • Loading branch information
pnoltes committed Feb 10, 2016
1 parent d4fe655 commit e3e6d1a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
3 changes: 0 additions & 3 deletions shell_tui/private/src/activator.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,6 @@ celix_status_t bundleActivator_stop(void * userData, bundle_context_pt context)
celix_status_t status;
shell_tui_activator_pt activator = (shell_tui_activator_pt) userData;

bundleContext_ungetService(activator->context,activator->reference,NULL);
bundleContext_ungetServiceReference(activator->context,activator->reference);

status = bundleContext_removeServiceListener(context, activator->listener);

if (status == CELIX_SUCCESS) {
Expand Down
2 changes: 1 addition & 1 deletion shell_tui/private/src/shell_tui.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ celix_status_t shellTui_serviceChanged(service_listener_pt listener, service_eve
status = shellTui_initializeService(act);
} else if ((event->type == OSGI_FRAMEWORK_SERVICE_EVENT_UNREGISTERING) && (equals)) {
bundleContext_ungetService(act->context, act->reference, &result);
bundleContext_ungetServiceReference(act->context,act->reference);
act->reference = NULL;
act->shell = NULL;

status = shellTui_initializeService(act);
}

return status;
Expand Down

0 comments on commit e3e6d1a

Please sign in to comment.