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

Re: [PATCH] WCNG: Enforce that a pristine checksum always references an entry in the pristine store.

From: Julian Foad <julian.foad_at_wandisco.com>
Date: Tue, 21 Dec 2010 12:49:07 +0000

Philip Martin wrote:
> Philip Martin <philip.martin_at_wandisco.com> writes:
>
> > Philip Martin <philip.martin_at_wandisco.com> writes:
> >
> >>> + SVN_ERR(svn_io_file_checksum2(&file_info->sha1_checksum, text_base_path,
> >>> + svn_checksum_sha1, result_pool));
> >>
> >> How much memory is allocated when checksumming a file? That's all going
> >> into the long-lived result pool. Perhaps we need a svn_stream_checksummed3
> >> that takes two pools?
> >
> > I mean svn_io_file_checksum3. I was trying to work out how much memory
> > was allocated.
>
> There is a 16K buffer per checksum, so 32K per file. We need a scratch
> pool, either explicitly in this function (and copy the checksum to
> result_pool) or in svn_io_file_checksum3.

Thanks, Philip. I fixed this by using the iterpool in this function and
then copying to result_pool, and fixed up the other two points you
mentioned.

Committed revision 1051475.

- Julian
Received on 2010-12-21 13:50:05 CET

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.