Menu

#31 safe file writing

open
nobody
wheat xml (14)
3
2004-07-22
2004-01-11
No

when XMLFileContainer writes a file, it should write to the
side, and only move over when all is okay - and perhaps
there needs to be a way for XMLWriter to signal all okay,
since if it throws in the middle we don't want the file
written over.

Discussion

  • Mark Lentczner

    Mark Lentczner - 2004-02-11
    • milestone: --> 375469
     
  • Mark Lentczner

    Mark Lentczner - 2004-02-11
    • milestone: 375469 --> future_release_cycle
     
  • Mark Lentczner

    Mark Lentczner - 2004-07-22
    • priority: 5 --> 3
     
  • Mark Lentczner

    Mark Lentczner - 2004-07-22

    Logged In: YES
    user_id=219202

    This has been implemented and mostly tested as of today.

    Only caveat is that the test doesn't check that XMLFileContainers with
    sub-containers are properly handled. In fact, in Safe mode they will not
    be since in is not possible to rename a dir onto a non-empty dir, and
    deleting a dir isn't implemented.

    Also, the test in xmlutil-test.cpp, could do a nicer job of cleaning the
    directly (in particular, handling non-empty dirs.)

     

Log in to post a comment.