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

Re: svn commit: r1631075 - in /subversion/trunk/subversion: libsvn_fs_fs/fs.h libsvn_fs_fs/fs_fs.c libsvn_fs_fs/structure libsvn_fs_fs/util.c tests/libsvn_fs/fs-test.c

From: Branko Čibej <brane_at_wandisco.com>
Date: Mon, 03 Nov 2014 15:47:52 +0100

On 11.10.2014 18:14, stefan2_at_apache.org wrote:
> Author: stefan2
> Date: Sat Oct 11 16:14:28 2014
> New Revision: 1631075
>
> URL: http://svn.apache.org/r1631075
> Log:
> Make FSFS format 7 use a different name for the 'transactions' folder.

> --- subversion/trunk/subversion/libsvn_fs_fs/util.c (original)
> +++ subversion/trunk/subversion/libsvn_fs_fs/util.c Sat Oct 11 16:14:28 2014
> @@ -237,7 +237,11 @@ const char *
> svn_fs_fs__path_txns_dir(svn_fs_t *fs,
> apr_pool_t *pool)
> {
> - return svn_dirent_join(fs->path, PATH_TXNS_DIR, pool);
> + fs_fs_data_t *ffd = fs->fsap_data;
> +
> + return ffd->format >= SVN_FS_FS__MIN_LOG_ADDRESSING_FORMAT
> + ? svn_dirent_join(fs->path, PATH_TXNS_LA_DIR, pool)
> + : svn_dirent_join(fs->path, PATH_TXNS_DIR, pool);
> }

Perhaps:

    const char *const txns_path =
      (ffd->format >= SVN_FS_FS__MIN_LOG_ADDRESSING_FORMAT
       ? PATH_TXNS_LA_DIR : PATH_TXNS_DIR);
    return svn_dirent_join(fs->path, txns_path, pool);

In any case, please put parentheses around conditional statements.

-- Brane
Received on 2014-11-03 15:49:57 CET

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