[sane-devel] RE: (Big?) Problem with fork() in OSX

Henning Meier-Geinitz henning@meier-geinitz.de
Tue, 17 Dec 2002 19:20:21 +0100


Hi,

On Tue, Dec 17, 2002 at 06:46:33PM +0100, Jaeger, Gerhard wrote:
> As the Plustek backend is not the only one that forks
> a reader process, the question should be how can this be solved
> for OSX?
> Any ideas?
> One might be the approach to have two versions one using
> the fork and one without (USE_FORK i.e. nec.c)...

If it's already implemented in the backend, it could be switched off
in configure. However, I wouldn't put much effort in eliminating fork
just because some operating system has problems with it.

> But I thought, that fork duplicates the entire process environment...

If the file descriptors aren't dup'ed, that should be fixed on MacOS
and not SANE. That's one of the basic Unix functions and if it doesn't
work, it's just not Unix.

However, bugs in fork would harm a lot of other applications so I
wonder if this is the real reason.

Bye,
  Henning