Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

Re: Monitoring directory for new files

by cdarke (Prior)
on Jan 20, 2010 at 06:31 UTC ( #818383=note: print w/ replies, xml ) Need Help??

in reply to Monitoring directory for new files

The only *true* way to avoid race conditions is to use the Win32 API ReadDirectoryChangesW with OVERLAPPED, and do that from C/C++.

Probably not what you want to hear, sorry.

Comment on Re: Monitoring directory for new files
Replies are listed 'Best First'.
Re^2: Monitoring directory for new files
by tokpela (Chaplain) on Jan 21, 2010 at 11:22 UTC

    Actually, there is a module on this site by D. Faure that encapsulates this API - Win32::ReadDirectoryChangesW.

    I found this a few weeks ago and have been using it in a test program and it works well enough for my purposes. I am in the process of moving (countries) but intend to ask D Faure if I can put this on CPAN when I get settled.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://818383]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (4)
As of 2015-11-29 22:51 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (754 votes), past polls