Ticket #121 (closed bug: fixed)
t/pmc/eval.t test10 fails on cygwin
Reported by: | rurban | Owned by: | rurban |
---|---|---|---|
Priority: | normal | Milestone: | 0.9.0 |
Component: | none | Version: | |
Severity: | medium | Keywords: | |
Cc: | Language: | ||
Patch status: | applied | Platform: | cygwin |
Description (last modified by rurban) (diff)
The "eval.get_string - same file" fails on cygwin with Permission denied.
It writes twice a temp pbc file, load_bytecode it and remove in the middle.
I guess that load_bytecode leaves a handle open,
therefore rm or open > fail with Permission denied.
On unices this will not fail because you can unlink open files, only on windows not. And I believe Windows is right here.
While debugging this test I see:
cd /tmp
ls -al
??????????? ? ? ? ? ? HhY9ocQ3wA.pbc
ls -al *.pbc
ls: cannot access HhY9ocQ3wA.pbc: No such file or directory
Note that cygwin has special code to circumvent unlink on open files, it deferes unlink until process end. And at the end of parrot this file is deleted.
But the problem seems to be bigger, because load_bytecode should not leave a handle open.