httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cliff Woolley <jwool...@virginia.edu>
Subject Re: cvs commit: httpd-2.0/modules/dav/main mod_dav.c
Date Wed, 06 Aug 2003 19:02:21 GMT
On Wed, 6 Aug 2003 nd@apache.org wrote:

>   +        bb = apr_brigade_create(r->pool, r->connection->bucket_alloc);
>   +
>   +        if (!bb) {
>   +            err = dav_new_error(r->pool, HTTP_INTERNAL_SERVER_ERROR, 0,
>   +                                "Could not create bucket brigade");
>   +        }
>   +        else {

Nit: apr_brigade_create() will never return NULL, so you don't need to
check for it.

--Cliff


APU_DECLARE(apr_bucket_brigade *) apr_brigade_create(apr_pool_t *p,
                                                     apr_bucket_alloc_t *list)
{
    apr_bucket_brigade *b;

    b = apr_palloc(p, sizeof(*b));
    b->p = p;
    b->bucket_alloc = list;

    APR_RING_INIT(&b->list, apr_bucket, link);

    apr_pool_cleanup_register(b->p, b, brigade_cleanup, apr_pool_cleanup_null);
    return b;
}

Mime
View raw message