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

Re: Upgrade to db 4.1

From: Zack Weinberg <zack_at_codesourcery.com>
Date: 2002-10-16 22:44:05 CEST

On Wed, Oct 16, 2002 at 11:27:02AM -0700, Justin Erenkrantz wrote:
> Well, some of the open calls do have their own transaction.
> Therefore, any such macro would have to realize when a NULL txn is
> passed that you have to then pass in DB_AUTO_COMMIT as well.
>
> # if BDB_VERSION > 4001
> # define BDB_OPEN_ARGS(db, txn, cr) \
> db, txn, #db, (cr ? (DB_CREAT | DB_EXCL) : 0) | \
> (txn ? 0 : DB_AUTO_COMMIT), 0666
> # else
> # define BDB_OPEN_ARGS(db, txn, cr) \
> db, #db, (cr ? (DB_CREAT | DB_EXCL) : 0), 0666
> # endif
>
> This scores really low on my beauty meter. -- justin

It is, however, prettier than having equivalent logic all over
libsvn_fs.

The question is whether compatibility with DB 4.0 is worth a certain
amount of ugliness -- I would say yes, because (as other people have
pointed out) 4.1 is not common yet.

zw

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Oct 16 22:44:51 2002

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.