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

RE: checksum bug, a great mystery.

From: Sander Striker <striker_at_apache.org>
Date: 2003-02-13 00:03:55 CET

> From: cmpilato@collab.net [mailto:cmpilato@collab.net]
> Sent: Wednesday, February 12, 2003 11:47 PM

> Brandon Ehle <azverkan@yahoo.com> writes:
>
> > As mentioned before the key is what happens with apr_md5_final() get
> > called with an empty context. The reason this is happening is because
> > apr_md5_final() can only be called once on a given context, as it will
> > clear the context after handing you the checksum. In this case its
> > because txn_body_write_close_rep() is calling apr_md5_final() twice on
> > the same context. If you add this patch, the error will go away.
>
> (patch removed)
>
> This looks like a Band-Aid(tm). Can we determine why apr_md5_final is
> being called twice and just fix that?

Yep. Here is the problem:

subversion/libsvn_fs/reps-strings.c:1083

      SVN_ERR (svn_fs__retry_txn (wb->fs,
                                  txn_body_write_close_rep,
                                  wb,
                                  wb->pool));

Which will call txn_body_write_close_rep n times. After the 1st one the
context is NUL'ed.

Sander

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Feb 13 00:04:36 2003

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