Re: walk_dir: upper & mixed case problem in "equal" test

new topic     » goto parent     » topic index » view thread      » older message » newer message

On 10 Sep 2000, at 20:26, Dan B Moyer wrote:

<snip>

> So the upshot is, if a person goes to use the routine, and types in the file
> name to find, if they don't type it in exactly the form it is returned by
> walk_dir (all uppercase, all lowercase, or *mixture*), I can't get the
> routine to recognize that it has found it.
>
> I presume I could make some routine to take each file name as reported by
> walk_dir and create *every* possible combination of upper/lower case for
> every character in it,  to do the test against the target filename, but this
> seems like it would make the walk_dir take a LOT longer to do.
>
> Can anyone suggest a better approach?

Yeas, upcase all the paths,, both the one found, and the one looked for, before
seeing
if they are equal.

Kat

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu