Module pointer not removed from registry when plugin load fails

Bug #616870 reported by Andrew Hutchings
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Drizzle
Fix Released
Medium
Andrew Hutchings
7.0
Fix Released
Medium
Andrew Hutchings
Dexter
Fix Released
Medium
Andrew Hutchings

Bug Description

When a module fails to initialize in plugin_finalize it is cleaned up but the module's pointer is still stored in registry so during shutdown the loader tries to remove the module again causing a segfault.

I have reproduced this by making InnoDB plugin fail to start.

To fix this the following code in plugin_finalize also needs to remove the module from the registry:

      if (plugin_initialize(registry, module))
        delete_module(module);

Related branches

Changed in drizzle:
importance: Undecided → Medium
Changed in drizzle:
assignee: nobody → Andrew Hutchings (thelinuxjedi)
status: New → Confirmed
Changed in drizzle:
status: Confirmed → In Progress
Revision history for this message
Andrew Hutchings (linuxjedi) wrote :

Awaiting Patrick to migrate some mtr2 features so we can build a test case for my fix

Changed in drizzle:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.