in reply to Problems sometimes loading File::Glob
This problem never happens with only one instance of the tool running, leading us to suspect concurrency issues (duh)
From your description I suspect the same, but I might be wrong. DLLs should be shared objects, shouldn't they? What's around line 68 of XSLoader?
Is Windows setting a lock on the DLL while opening it, then releasing the lock? That would be an explanation, but really bad behaviour also.
eval seems the way to go, but not around the glob() calls - it should go around the use File::Glob call in a loop, retrying after a small amount of time and aborting after $count tries, since the DLL is bootstrapped upon loading the module AFAIK.
sm<update>
After seeing your post above, I'd sugges to try the BEGIN block trick to not defer the loading of File::Glob to the compiler.
</update>
--shmem
_($_=" "x(1<<5)."?\n".q·/)Oo. G°\ /
/\_¯/(q /
---------------------------- \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Problems sometimes loading File::Glob
by HuckinFappy (Pilgrim) on May 23, 2007 at 18:20 UTC | |
by shmem (Chancellor) on May 23, 2007 at 18:37 UTC | |
by HuckinFappy (Pilgrim) on May 24, 2007 at 22:57 UTC |