summaryrefslogtreecommitdiff
path: root/buckets/apr_buckets_refcount.c
diff options
context:
space:
mode:
authorjwoolley <jwoolley@13f79535-47bb-0310-9956-ffa450edef68>2001-02-28 17:52:46 +0000
committerjwoolley <jwoolley@13f79535-47bb-0310-9956-ffa450edef68>2001-02-28 17:52:46 +0000
commit54ef30e46b6e151a5e6ef05e902922411ffdf15a (patch)
treec93fd0dc6041372a6155df49f7c0d5231a200984 /buckets/apr_buckets_refcount.c
parentbd24f5ff064615c0afb0b814ea91f09047038e48 (diff)
downloadlibapr-util-54ef30e46b6e151a5e6ef05e902922411ffdf15a.tar.gz
apr_bucket_shared_destroy() now returns a boolean value
instead of a pointer, since the caller already knew the pointer value anyway. (Issue #8 from the "Bucket API cleanup issues" thread.) git-svn-id: http://svn.apache.org/repos/asf/apr/apr-util/trunk@58148 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'buckets/apr_buckets_refcount.c')
-rw-r--r--buckets/apr_buckets_refcount.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/buckets/apr_buckets_refcount.c b/buckets/apr_buckets_refcount.c
index 1f3ef3d2..f276cce9 100644
--- a/buckets/apr_buckets_refcount.c
+++ b/buckets/apr_buckets_refcount.c
@@ -52,10 +52,6 @@
* <http://www.apache.org/>.
*/
-#include <stdlib.h>
-
-#include "apr_errno.h"
-
#include "apr_buckets.h"
APU_DECLARE_NONSTD(apr_status_t) apr_bucket_shared_split(apr_bucket *a,
@@ -86,12 +82,11 @@ APU_DECLARE_NONSTD(apr_status_t) apr_bucket_shared_copy(apr_bucket *a,
return APR_SUCCESS;
}
-/* XXX: can this just return true or false? */
-APU_DECLARE(void *) apr_bucket_shared_destroy(void *data)
+APU_DECLARE(int) apr_bucket_shared_destroy(void *data)
{
apr_bucket_refcount *r = data;
r->refcount--;
- return (r->refcount == 0) ? r : NULL;
+ return (r->refcount == 0);
}
APU_DECLARE(apr_bucket *) apr_bucket_shared_make(apr_bucket *b, void *data,