[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 V2

From: Garrett Rooney <rooneg_at_electricjellyfish.net>
Date: 2005-11-02 00:40:13 CET

On 10/31/05, Madan U Sreenivasan <madan@collab.net> wrote:

In the change to subversion/libsvn_repos/commit.c:

+++ subversion/libsvn_repos/commit.c (working copy)
@@ -664,6 +664,7 @@
   svn_revnum_t new_revision = SVN_INVALID_REVNUM;
   svn_error_t *err;
   const char *conflict;
+ char *post_commit_err = NULL;

   /* If no transaction has been created (ie. if open_root wasn't
      called before close_edit), abort the operation here with an
@@ -702,12 +703,13 @@
     }
   else if (err)
     {
- /* ### TODO: ra_local is the only RA layer that currently
- understands SVN_ERR_REPOS_POST_COMMIT_HOOK_FAILED. And as of
- at least r12960, svn_repos_fs_commit_txn() would never return
- that anyway. If someone who knows ra_svn better can add
- handling for this special case, this whole "else if" block
- can go away (again). */
+ /* Post-commit hook's failure output can be passed back to the
+ client. However, this cannot be a commit failure. Hence
+ passing back the post-commit error message as a string to
+ be displayed as a warning. */
+ if (err->child->message)
+ post_commit_err = apr_pstrdup (pool, err->child->message) ;
+

Is there any chance that err->child could be NULL?

Also, this file doesn't appear in the log message.

-garrett

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Nov 2 00:41:07 2005

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