2008-05-26

Equinox HttpContextManager Bug

There is a bug in the Eclipse Equinox implementation of HttpContextManager (version 1.0.0.v20070608).  It throws an array out-of-bounds exception on line 91:

for (int j = 0; j < resourceMappingElements.length; j++) {
    IConfigurationElement resourceMappingElement = resourceMappingElements[i];

i is the wrong index variable.  It should be j.

This code will only work when there is only one context with no more than one resource mapping.