Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Reopen file when contents changed?

by thcsoft (Monk)
on Jun 07, 2005 at 14:09 UTC ( [id://464311]=note: print w/replies, xml ) Need Help??


in reply to Reopen file when contents changed?

if you're on a unix/linux system, you'ld be better off with a shell script.

language is a virus from outer space.

Replies are listed 'Best First'.
Re^2: Reopen file when contents changed?
by bofh_of_oz (Hermit) on Jun 07, 2005 at 14:34 UTC
    Possibly, but AFAIK forking a shell requires resources, which will impact the measurements; opening a file will not...

    --------------------------------
    An idea is not responsible for the people who believe in it...

      Forking anything would require resources... There is no need to fork just to read the contents of a file. But anyway, I think keeping the file open and just seek(0) is easier than opening the file everytime. I don't know how much impact open() would generate on load, but I do think seek(0) would cause even less impact.
Re^2: Reopen file when contents changed?
by salva (Canon) on Jun 07, 2005 at 14:33 UTC
    why?

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (4)
As of 2024-04-25 17:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found