Fix moronic index computation error which would make "Add all" would dump core if directory contained subdirs