Re: Problem with NSFileManger directoryContentsAtPath
Re: Problem with NSFileManger directoryContentsAtPath
- Subject: Re: Problem with NSFileManger directoryContentsAtPath
- From: "Hamish Allan" <email@hidden>
- Date: Fri, 16 May 2008 15:04:40 +0100
On Fri, May 16, 2008 at 6:02 AM, JanakiRam <email@hidden> wrote:
> When i perform ls command it shows file name as "Icon?". When i perform cp
> command & tab it shows the file name as "Icon^M".
> Why Terminal does show different names for the same file.
Because the filename contains a non-printing character
(http://en.wikipedia.org/wiki/Control_character). "bash" (which is
what is performing the tab completion) and "ls" have different ways of
denoting non-printing characters. NSLog is treating it as if there is
an implicit line feed.
> When i see it in
> Finder it does show as "Icon".
This would suggest that the Finder has been designed not to indicate
the presence of non-printing characters.
> Please advise. Thanks in Advance.
Advise you about what, though? You say that "for some files it is
failing", but the code you included seems to be working perfectly.
Hamish
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden