Version française
Home     About     Download     Resources     Contact us    
Browse thread
Re: [Caml-list] file mapped bigarray and Unix.unlink
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Dario Teixeira <darioteixeira@y...>
Subject: Re: [Caml-list] file mapped bigarray and Unix.unlink

Hi,

> > The strategy I adopted is to spawn a recursive thread that
> > periodically try to erase the file until success.
> 
> That seems the wrong solution to me. The unlink syscall should work
> immediately or you have another reason why it only works after a
> certain time.

I second David's discomfort.  Have you considered issuing a sync after
the unlink?  For efficiency reasons the OS may not actually be deleting
the file immediately after the unlink; the sync should force it to do it.

Cheers,
Dario Teixeira