ltsv_is_valid_name: Replace pattern check logic