check exact matches before stripping (fixes #452)