#1 2013-05-31 10:36:03

Oleg
Member
Registered: 2013-05-24
Posts: 2

Service unregistering

Hi,

I'm trying to implement dynamic service loading/unloading vs your Framework.
My task is:
(1) to load SO with dlopen ()
(2) to use it (somehow)
(3) and to close it with dlclose ().

First step implies registering of SampleService in the Framework (RegisterService).
At the second step I use Framework to get access to SampleService (GetServiceReference and GetService).
The last step calls UngetService() for the reference, then ServiceRegistration::Unregister() method, and finally dlclose ().

Actually all three part works well and dynamically loaded module is indeed destroyed. But ...
When I call GetModuleContext()->GetModules() I still see my dynamically unloaded module in the list and that is obviously wrong.
How to remove it from the list of modules?

Thanks,
Oleg

Offline

#2 2013-06-02 11:13:17

sascha
Administrator
Registered: 2012-05-04
Posts: 45

Re: Service unregistering

Offline

#3 2013-06-03 07:29:24

Oleg
Member
Registered: 2013-05-24
Posts: 2

Re: Service unregistering

Hi Sascha,

thanks. I've missed this point.

Regards,
Oleg

Offline

Board footer

Powered by FluxBB