Greg Stein wrote:

On Wed, Jul 28, 2004 at 08:08:05PM -0400, Ryan Bloom wrote:

Basically, the macro is wrong and needs to be removed.  The contract
that _all_ APR API's live up to is that on a successful result, they
must return APR_SUCCESS.  The reason we chose to use 0 as success is
simple:


Yup. The contract is that success is 0. There is no "system success" --
APR should translate any/all underlying success values into 0 upon return.

So I fully ocncur with the original design contract -- both in terms of
what the history and design said it should be, and how I (still) think it
should operate.

I'm with Ryan on calling that macro wrong, and just tossing it. We tossed
its use from SVN a long time ago and just relied on the ==0 contract.

$ find . -name \*.c -exec grep -q APR_STATUS_IS_SUCCESS {} \; -print ./subversion/libsvn_fs_fs/fs_fs.c ./subversion/libsvn_ra_svn/cram.c ./subversion/libsvn_ra_svn/marshal.c ./subversion/libsvn_subr/io.c ./subversion/tests/libsvn_delta/svndiff-test.c ./subversion/tests/libsvn_delta/vdelta-test.c $

Apparently it's crept back in.

-garrett



Reply via email to