• 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: Bug in pathContentOfSymbolicLinkAtPath?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug in pathContentOfSymbolicLinkAtPath?


  • Subject: Re: Bug in pathContentOfSymbolicLinkAtPath?
  • From: Chris Garaffa <email@hidden>
  • Date: Sat, 01 Sep 2001 11:57:57 -0400

/etc is a symbolic link to /private/etc
Go into the Terminal application, su to root (this may/may not be necessary; I am logged in as root), and type
cd / (to get to the / directory)
ls -l | grep etc (ls -l lists all the items in the current directory, plus their permissions, owners, groups, etc. piping it to grep [using | ] as I did shows only lines which have the string "etc" in them)
this outputs:
lrwxrwxr-t 1 root admin 11 Aug 31 18:58 etc -> private/etc
which means, basically that this is a symbolic link to /private/etc owned by root who is in the group admin.
The way to determine is something is a link, file or directory is to look at the first character of this line:
l means "link" (symbolic link, equivalent to Classic MacOS aliases.)
- means file
d means directory

Hope this helps,
Chris Garaffa


On Saturday, September 1, 2001, at 08:44 PM, j o a r wrote:

Hello,

Could any one explain why "pathContentOfSymbolicLinkAtPath:" from NSFileManager returns "private/etc" when I feed it"/etc"? Shouldn't it be "/private/etc/"?

The docs state:

//***********************************************************************
*
*********
pathContentOfSymbolicLinkAtPath:

- (NSString *)pathContentOfSymbolicLinkAtPath:(NSString *)cStringPath
Returns the actual path of the directory or file that the symbolic link cStringPath refers to. Returns nil upon failure.
//***********************************************************************
*
*********

j o a r
_______________________________________________
cocoa-dev mailing list
email@hidden
http://www.lists.apple.com/mailman/listinfo/cocoa-dev


References: 
 >Bug in pathContentOfSymbolicLinkAtPath? (From: j o a r <email@hidden>)

  • Prev by Date: Bug in pathContentOfSymbolicLinkAtPath?
  • Next by Date: Sorry (was: Re: Bug in pathContentOfSymbolicLinkAtPath?)
  • Previous by thread: Bug in pathContentOfSymbolicLinkAtPath?
  • Next by thread: Sorry (was: Re: Bug in pathContentOfSymbolicLinkAtPath?)
  • Index(es):
    • Date
    • Thread