This is because our path may have dots in it (for example bin/../logs/master.log, and we want to split the suffix on the last dot not the first one which may be in the path.