Fixed problems with a dots in a filenames - Issue #2875

I've made the final fix.