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

Re: svn commit: r1381817 - /subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c

From: Daniel Shahaf <danielsh_at_elego.de>
Date: Mon, 10 Sep 2012 19:04:08 +0100

stefan2_at_apache.org wrote on Fri, Sep 07, 2012 at 00:22:46 -0000:
> Author: stefan2
> Date: Fri Sep 7 00:22:45 2012
> New Revision: 1381817
>
> URL: http://svn.apache.org/viewvc?rev=1381817&view=rev
> Log:
> Follow-up to r1381814.
>
> * subversion/libsvn_fs_fs/fs_fs.c
> (get_dir_contents): expanded_size may not be given

Can you explain this please? The structure file says that the expanded
size and the md5sum are always present (but the sha1 and uniquifier are
not present in reps written by pre-format-4 servers). Under what
circumstances is expanded_size unknown?

>
> Modified:
> subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c
>
> Modified: subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c
> URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c?rev=1381817&r1=1381816&r2=1381817&view=diff
> ==============================================================================
> --- subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c (original)
> +++ subversion/trunk/subversion/libsvn_fs_fs/fs_fs.c Fri Sep 7 00:22:45 2012
> @@ -5070,7 +5070,9 @@ get_dir_contents(apr_hash_t *entries,
> * parse it byte-by-byte.
> */
> apr_pool_t *text_pool = svn_pool_create(pool);
> - apr_size_t len = noderev->data_rep->expanded_size;
> + apr_size_t len = noderev->data_rep->expanded_size
> + ? noderev->data_rep->expanded_size
> + : noderev->data_rep->size;
> svn_stringbuf_t *text = svn_stringbuf_create_ensure(len, text_pool);
> text->len = len;
>
>
>
Received on 2012-09-10 20:04:44 CEST

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.