in reply to Re^3: Why no LockFile() in Win32API::File ?
in thread Why no LockFile() in Win32API::File ?

Now, perhaps you can explain why my attempt to use it doesn't work?

I think its because DATA and *DATA arent filedescriptors (int fd). In order to make that work you have to get the fd for the perl filehandle. The way I understand it is you have three handles, the perl level one, the unix file descriptor one, and the win32 handle under that. Im not sure if (or rather to what extent) the unix level one is supported by the Win32 API and what is provided by perl for portability reasons, but obviously the win32 handle one doesn't exist on UNIX at all.

Bear in mind i havent inspected the code before replying to this, so its just conjecture based on recollection.

---
$world=~s/war/peace/g

  • Comment on Re^4: Why no LockFile() in Win32API::File ?