apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Orton <jor...@redhat.com>
Subject Re: error code range for apr-util
Date Thu, 22 Jun 2006 18:29:55 GMT
On Thu, Jun 22, 2006 at 05:09:09PM +0100, david reid wrote:
> I'd like to add a "reserved" range for error codes in apr-util. Given
> that we allow 50,000 for the gap between apr codes and those we advise
> apps to use (APR_OS_START_STATUS and APR_OS_START_USERERR) would using
> the "2nd half" of that gap (or less) make sense for apr-util? It would
> mean we avoid potential conflicts and keeps it out of the area we have
> said is reserved for apps - so makes sense to me.
> It would gain a define of APR_UTIL_START_STATUS or some such which would
> be set at APR_OS_START_STATUS + (APR_OS_ERRSPACE_SIZE / 2) (for example)

Great idea, I can't see any problems with doing that.

> Anyone remember why we don't have an apr_pstrerror()? Having to create
> and pass a buffer to apr-strerror seems very un-apr-like.

With the trunk APR you can do:

  apr_status_t rv = apr_doit();
  apr_psprintf("error was %pm\n", &rv);

which simplifies most cases.


View raw message