[Bug 1231323] core dump (Segmentation fault) when ending repository management
https://bugzilla.suse.com/show_bug.cgi?id=1231323 https://bugzilla.suse.com/show_bug.cgi?id=1231323#c15 Michael Andres <ma@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Flags|needinfo?(zypp-maintainers@ | |suse.de) | --- Comment #15 from Michael Andres <ma@suse.com> --- No real clue. But the immediate end of the log is strange. No core available? ~PkgFunctions() resets the zypp_pointer and the `y2milestone("Zypp pointer released")` logline works. AFAICS `PkgFunctions pkg_functions;` is owned by `class PkgModuleFunctions`. `class PkgModule` inherits `public PkgModuleFunctions` and appears to be a singleton with `static PkgModule* instance ();` and `static void destroy();`. PkgModule::instance redirects zypp::base::LogControl::instance().setLineWriter and setLineFormater to YaSTZyppLogger / YaSTZyppFormatter and creates a new PkgModule. Wich is finally owned by the global variable to register this component creator: `Y2CCPkg g_y2ccPkg;` Now ~Y2CCPkg triggers the deletion. PkgModule::destroy deletes the PkgModule (so the PkgModuleFunctions and the PkgFunctions it owns). Thats's what you see in the log:
16:33:35 <0> [Pkg] Y2CCPkg.cc(~Y2CCPkg):64 ~Y2CCPkg 16:33:35 <0> [Pkg] PkgModule.cc(destroy):101 Deleting PkgModule object... 16:33:35 <0> [Pkg] Callbacks.cc(~CallbackHandler):1925 Deleting callback handler 16:33:35 <1> [Pkg] PkgFunctions.cc(~PkgFunctions):152 Releasing the repo manager... 16:33:35 <1> [Pkg] PkgFunctions.cc(~PkgFunctions):159 Releasing the zypp pointer... 16:33:35 <1> [Pkg] PkgFunctions.cc(~PkgFunctions):161 Zypp pointer released
~Y2CCPkg - as a global static variable `Y2CCPkg g_y2ccPkg` - is triggered by unloading the y2pkg libbrary. Your objects are destructed, but the zypp::base::LogControl::instance().setLineWriter and setLineFormater still refer to YaSTZyppLogger / YaSTZyppFormatter objects. If zypp now logs something it might lead to calling functions in your domain while the lib is no longer loaded. -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@suse.com