Library init routines should be idempotent

Description

Originally filed by Luke Howard, moved from old Jira.

I have multiple non-cooperating libraries that link against Shibboleth SP/Resolver (along with OpenSAML, etc). Calling ShibbolethResolver::init() multiple times in a process appears to cause crashes (and not calling it in one library obviously is very dependent on whether the other library is installed or loaded first). I'm using the following workaround now:

if (!didShibInit && SPConfig::getConfig().getFeatures() == 0) {
ShibbolethResolver::init();
didShibInit = TRUE;
}

But I'd really like to get it fixed properly.

Environment

None

Activity

Fixed

Details

Assignee

Reporter

Original estimate

Components

Fix versions

Affects versions

Created May 27, 2011 at 6:48 PM
Updated July 7, 2011 at 1:56 AM
Resolved June 6, 2011 at 7:27 PM