[Top][All Lists]

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

Re: NSSearchPathForDirectoriesInDomains and non-existing directories

From: David Ayers
Subject: Re: NSSearchPathForDirectoriesInDomains and non-existing directories
Date: Tue, 25 Oct 2005 10:14:04 +0200
User-agent: Mozilla Thunderbird 1.0.2 (X11/20051002)

Sheldon Gill schrieb:
> It isn't in
> NSSearchPath() but rather the calling code. Creation of a path isn't and
> shouldn't be the responsibility of NSSearchPath(). That needs to be
> handled elsewhere. Generally it is, by the way.

Indeed there are two issues at hand.

1.) NSColorList has to deal with NSSearchPath returning an empty array.
2.) creating the expected user directory layout, and creating it "in
time" for such usage as 1.) which I believe implies:
  a.) We created it when sourcing GNUstep.[csh] (just kidding :-) )
  b.) Creating the directory layout in +[NSObject initialize] or
  c.) auditing core for NSSearchPath usage and calling an "internal"
function/macro to create them just before the relevant invocations.

I'm leaning towards b.) as it just seems more straight forward and
reliable and I'm not sure whether it's worth while to try to avoid the

But it would also mean that every little tool will have to at least read
from disk to see if the layout exists.  I'm not too thrilled about that,
but that may already be the case currently wrt user defaults.  I haven't
had the time to verify that though.


reply via email to

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