Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^2: Inplace edit using XML::Twig

by gellyfish (Monsignor)
on May 22, 2006 at 08:34 UTC ( #550878=note: print w/ replies, xml ) Need Help??


in reply to Re: Inplace edit using XML::Twig
in thread Inplace edit using XML::Twig

There are two reasons, firstly renaming is an atomic operation on all the systems that I am aware of so there is no risk of another application that can't be made to co-operate with this one getting a partially written file, secondly writing to a second file mitigates against the risk of the file being corrupted if the process is interrupted due to a program or OS crash or hardware failure for instance. For the most part I would omit the deletion stage to further reduce the risk of losing the file (although some OS might not support this).

/J\


Comment on Re^2: Inplace edit using XML::Twig

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (10)
As of 2015-07-30 08:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (270 votes), past polls