bug-sh-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bug in basename ?


From: Uwe H. Steinfeld
Subject: Re: bug in basename ?
Date: Wed, 21 Feb 2001 18:41:50 +0100

----- Original Message -----
From: <address@hidden>
To: <address@hidden>
Sent: Tuesday, February 20, 2001 6:57 PM
Subject: bug in basename ?


>
> In using basename I ran across the following condition
> that seems to be incorrect:
>
>     basename a.b/c .b
>
> Produces:
>     c
>
>
> info basename says that the suffix is removed only
> if it is identical to the END of the name.
> Am I reading this incorrectly?

Yes, but only half of it. The first sentence says:

    `basename' removes any leading directory components from NAME.

So, "a.b/c" becomes just "c". Afterwards the suffix is checked for a
possible match.

Greetings
Uwe





reply via email to

[Prev in Thread] Current Thread [Next in Thread]