On Sun, 2012-08-12 at 23:18 -0700, Evan Laforge wrote: > Yes, I ran into the same thing a while back. The problem is that the > subprocess has already been forked off before it runs exec() and finds > out the file doesn't exist.
Given how astonishingly common it is to pass an invalid executable name and/or path, wouldn't it be worth doing a quick probe to see if the file exists before createProcess actually forks? [It's not like the effort the OS is going to do for the stat is going to be thrown away; whether that call pulls it up off of disk or the one after the fork that exec will do doesn't matter] AfC Sydney
signature.asc
Description: This is a digitally signed message part
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe