Changed cmd_path so that older paths are searched first.