[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: The (hopefully) final BDB-4.4 fix

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2006-03-13 01:23:38 CET

This looks reasonable as far as I can tell, but my say-so isn't worth much
because I'm not at all aware of the variety of tear-down scenarios that are
possible.

Branko Čibej wrote:
> Here's a slightly updated version of this patch; mostly typo fixes and
> such.

> Index: subversion/libsvn_fs_base/bdb/env.c
> ===================================================================
> --- subversion/libsvn_fs_base/bdb/env.c (revision 18856)
> +++ subversion/libsvn_fs_base/bdb/env.c (working copy)
> @@ -214,6 +214,7 @@
> bdb_baton.env = bdb->env;
> bdb_baton.bdb = bdb;
> bdb_baton.error_info = get_error_info(bdb);
> + bdb_baton.valid = TRUE;
> SVN_BDB_ERR(&bdb_baton, db_err);
> }
> return SVN_NO_ERROR;
> @@ -509,6 +510,7 @@
> return err;
> }
>
> +static apr_status_t invalidate_env_baton(void *data);

Not being terribly keen on forward declarations, I'd suggest moving the
function definition to here.

[...]
> Index: subversion/libsvn_fs_base/bdb/env.h
> ===================================================================
> --- subversion/libsvn_fs_base/bdb/env.h (revision 18856)
> +++ subversion/libsvn_fs_base/bdb/env.h (working copy)
> @@ -73,7 +73,7 @@
> typedef struct
> {
> /* The Berkeley DB environment. This pointer must be identical to
> - the one in bdb_env_t. */
> + the one in the bdb_env_t. */
> DB_ENV *env;
>
> /* The (opaque) cached environemnt descriptor. */

You might want to fix "environemnt" since you're doing typo fixes in this struct.

> @@ -82,6 +82,19 @@
> /* The error info related to this baton. */
> bdb_error_info_t *error_info;
>
> + /* This flag determines if the environment baton points to a valid
> + environment descriptor. It is used for inetrnal bookkeeping and

"in-what" bookkeeping? :-)

> + pool lifetime disambiguation, and need not be checked by the user
> + of the baton.

- Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Mar 13 01:23:57 2006

This is an archived mail posted to the Subversion Dev mailing list.