in reply to Safe to run a constant loop?
really no need to use the sleep. and GOTO's should be gone with QBASIC :). Something as simple as this, don't worry about CPU usage, I would be ammused to see if this even sparked a blip on the "top" radar. tradezwhile (1) { opendir (DIR, $watcheddir); @files=grep {!/^\./} readdir (DIR); closedir DIR; foreach $currentfile (@files) { &filecontents; } }
|
|---|