Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Got LibraryUnloadException on correct unloading #227

Open
roversch opened this issue Dec 24, 2021 · 0 comments
Open

Got LibraryUnloadException on correct unloading #227

roversch opened this issue Dec 24, 2021 · 0 comments

Comments

@roversch
Copy link

I'm on 1.13.0-1focal.20210727.062753 with ROS noetic.

I have the following plugin situation, both are part of the same dynamic library:

  <class type="Child1" base_class_type="Parent"/>
  <class type="Child2" base_class_type="Parent"/>

When I call createUnmanagedInstance with the name of Child1, it correctly gets resolved_library_path_ set. When I do the same for Child2, it is not updated from UNRESOLVED.

When I then try to call unloadLibraryForClass, the Child1 is correctly unloaded, but for Child2 I get LibraryUnloadException, since there is a check for the resolved_library_path_:

  if (it != classes_available_.end() && it->second.resolved_library_path_ != "UNRESOLVED") {
    ...
  }

Basically, I'm not able to correctly unload it.

How can I get around this? Is it correct to assume that resolved_library_path_ should always be set, and thus we have a bug here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant