• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Case sensitive fileName
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Case sensitive fileName


  • Subject: Re: Case sensitive fileName
  • From: Michael Davey <email@hidden>
  • Date: Wed, 17 Mar 2010 16:19:57 +0000

I don't think that the OP wanted to iterate through the entire directory though...

On 17 Mar 2010, at 16:15, Don Quixote de la Mancha wrote:

> Does readdir work on Mac OS X?  I don't have a Mac handy right now to
> check, but it should work because so many *NIX programs build on OS X
> right out of the box.
>
> More or less what you do is call opendir on a directory, then
> rewinddir to set your iterator to the beginning of the directory, then
> repeatedly call readdir to read each of the items in the directory.
>
> This is actually a portable and standardized interface to reading the
> directory inode.
>
> Note that there is both a readdir system call and a readdir library
> call.  You want the library call.  The system call is there for the
> private use of the library call, and isn't meant to make sense or be
> portable.
>
> If readdir does work on OS X, it will get you the filename as it is
> actually found in the filesystem - that is, with the case preserved.
>
> Look up "man 3 readdir" and friends.
>
> Don Quixote
> --
> Don Quixote de la Mancha
> email@hidden
> http://www.dulcineatech.com
>
>   Dulcinea Technologies Corporation: Software of Elegance and Beauty.
> _______________________________________________
>
> 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

_______________________________________________

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

  • Follow-Ups:
    • Re: Case sensitive fileName
      • From: Don Quixote de la Mancha <email@hidden>
References: 
 >Case sensitive fileName (From: "gMail.com" <email@hidden>)
 >Re: Case sensitive fileName (From: Jens Alfke <email@hidden>)
 >Re: Case sensitive fileName (From: Don Quixote de la Mancha <email@hidden>)

  • Prev by Date: Re: Case sensitive fileName
  • Next by Date: Re: Case sensitive fileName
  • Previous by thread: Re: Case sensitive fileName
  • Next by thread: Re: Case sensitive fileName
  • Index(es):
    • Date
    • Thread