handle multiple configuration files correctly. Patch by Pieter Grimmerink