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

Re: side note to ppfChdir

Pierre Phaneuf wrote:

>You could virtualize the cwd by keeping it in a variable and pre-pending
>it if the file name doesn't begin with a directory separator. If the
>user want to *really* change the cwd, he simply has to use chdir(). You
>*could* some state information in addition to the simple path string to
>potentially accelerate some pak file functions, but the stdio calls
>would get fully qualified paths.

Okok. I thought a bit about this and it can be quite nicely with the new
URL processing code. I however don't like the idea if doing allocations and
string copies at almost every ppfOpen () call. But then eliminating use of
chdir () would remove another little system dependency.

Good. We'll do it like this:
For now we stick with chdir, at least until PFile is reasonably stable. But
I'll add it to the TODO list, and later we will switch to this
all-plain-paths-are-absolutized method - *if* profiler and benchmarks say
that the additional processing is ok.

>Don't worry about me, will ya? :-) By day, I'm a system analyst on
>weather modeling supercomputers, worrying about clustering-related
>multithreaded kernel deadlock problems in high performance applications
>and things like that. Layered storage subsystems, I also meddle with.

Eck! I hope you *really* like your work...

>> Until that is ready, please trust me that chdir () *should* be called ;)
>I don't trust you a second, I guess that's why I like the open source
>development model. ;-)

Grrrrrr :-[]


Drive A: not responding...Formatting C: instead