Re: Testing sub directories using perl AGAIN

1999-04-28 Thread Ian Peters
On Wed, Apr 28, 1999 at 01:42:48PM +, Shao Zhang wrote: > But it is still not exactly what I want. All the answers used the > idea to compare the string, but what about > the following case: > > dir1 = "/www/info/world"; > dir2 = "/www/info/world/usa/../../../." > > Now, clearly dir1 is a

Re: Testing sub directories using perl AGAIN

1999-04-28 Thread Joey Hess
Shao Zhang wrote: > But it is still not exactly what I want. All the answers used the > idea to compare the string, but what about > the following case: > > dir1 = "/www/info/world"; > dir2 = "/www/info/world/usa/../../../." > > Now, clearly dir1 is a sub directory of dir2. So how do I test.

Re: Testing sub directories using perl AGAIN

1999-04-28 Thread James M . Mastros
On Wed, Apr 28, 1999 at 01:42:48PM +, Shao Zhang wrote: > But it is still not exactly what I want. All the answers used the > idea to compare the string, but what about > the following case: > > dir1 = "/www/info/world"; > dir2 = "/www/info/world/usa/../../../." > > Now, clearly dir1 is a