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

Re: [PATCH] Issue 443 : post-commit hook (error) output lost: Step 6

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2005-10-19 23:40:29 CEST

Madan U Sreenivasan <madan@collab.net> writes:

> --- subversion/mod_dav_svn/version.c (revision 16776)
> +++ subversion/mod_dav_svn/version.c (working copy)
> @@ -1614,6 +1614,7 @@
> svn_fs_txn_t *txn;
> const char *conflict;
> svn_error_t *serr;
> + char *post_commit_err = NULL;
> svn_revnum_t new_rev;
> apr_hash_t *locks;
> svn_boolean_t disable_merge_response = FALSE;
> @@ -1694,7 +1695,11 @@
> return dav_svn_convert_err(serr, HTTP_CONFLICT, msg, pool);
> }
> else if (serr)
> - svn_error_clear(serr);
> + {
> + if (serr->child->message)
> + post_commit_err = apr_pstrdup (pool, serr->child->message);

If serr->child is NULL you dump core. It all looks a bit dodgy, you
are building detailed knowledge of the structure of the repository
error chain into mod_dav_svn. I'm not quite sure what you are trying
to do, but if you are looking for a particular error then perhaps you
should iterate through the list checking apr_err?

> + svn_error_clear(serr);
> + }

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Oct 19 23:41:20 2005

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.