apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Davi Arnaut <d...@haxent.com.br>
Subject Re: Regarding apr_file_writev() and locking...
Date Sat, 12 May 2007 01:38:01 GMT
Bojan Smojver wrote:
> On Fri, 2007-05-11 at 15:58 +0100, Joe Orton wrote:
>> Yes, that looks necessary.
> Thanks, cool. Will implement. Honestly, even apr_file_flush() looks a
> bit suspect to me.

I've just posted a few initial patches to bugzilla, PR 42400. (passes

The patches improves the locking interaction with buffering. But, quite
frankly, the unix file_io locking and buffering is a bit messed. There
is no clear indication which functions are protected by APR_XTHREAD,
checks for partial writes on flushing are missing, buffering and file
positioning don't play well together, et cetera.

I am in the middle of writing a patch that converts all file_io to
standard i/o functions (stdio/streams) so we can remove all code
involving buffering, file positioning and even locking at some cases. It
saves a huge amount of code lines, and I hope, gives fewer bugs.


Davi Arnaut

View raw message