fix problem with multiple files named a.*.xml

As I haven't heard anything anymore on Issue #226, I made the change proposed by rneatherway.