You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Kamesh Jayachandran <ka...@collab.net> on 2010/12/26 06:40:46 UTC
RE: svn commit: r1052817 - /subversion/trunk/subversion/tests/libsvn_subr/error-test.c
>+
>+ err2 = svn_error_purge_tracing(err);
>+ for (child = err2; child; child = child->child)
>+ if (svn_error__is_tracing_link(child))
>+ {
>+ return svn_error_create(SVN_ERR_TEST_FAILED, err,
>+ "Tracing link found after purging the "
>+ "following chain:");
>+ }
>+
>+ svn_error_clear(err);
The doc of svn_error_purge_tracing(err) says err should *not* be cleared.
<snip>
/**
* Purge from @a err and its child chain any links associated with
* error tracing placeholders, and return the new top-level error
* chain item. @a err should be considered unusable after passing
* through this function, but should *not* be cleared (as the returned
* error shares memory with @a err). @a err can be #SVN_NO_ERROR.
*
* @since New in 1.7.
*/
svn_error_t *svn_error_purge_tracing(svn_error_t *err);
</snip>
Are you sure?
With regards
Kamesh Jayachandran
Re: svn commit: r1052817 - /subversion/trunk/subversion/tests/libsvn_subr/error-test.c
Posted by Blair Zajac <bl...@orcaware.com>.
On 12/25/10 10:40 PM, Kamesh Jayachandran wrote:
>> +
>> + err2 = svn_error_purge_tracing(err);
>> + for (child = err2; child; child = child->child)
>> + if (svn_error__is_tracing_link(child))
>> + {
>> + return svn_error_create(SVN_ERR_TEST_FAILED, err,
>> + "Tracing link found after purging the "
>> + "following chain:");
>> + }
>> +
>> + svn_error_clear(err);
>
> The doc of svn_error_purge_tracing(err) says err should *not* be cleared.
Right, but it can be cleared if you look at the implementation. I think I'll be
updating svn_error_purge_tracing(), either the docs or the implementation.
Blair
Re: svn commit: r1052817 -
/subversion/trunk/subversion/tests/libsvn_subr/error-test.c
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
You're quoting an old version of the docstring.
Kamesh Jayachandran wrote on Sun, Dec 26, 2010 at 12:10:46 +0530:
> >+
> >+ err2 = svn_error_purge_tracing(err);
> >+ for (child = err2; child; child = child->child)
> >+ if (svn_error__is_tracing_link(child))
> >+ {
> >+ return svn_error_create(SVN_ERR_TEST_FAILED, err,
> >+ "Tracing link found after purging the "
> >+ "following chain:");
> >+ }
> >+
> >+ svn_error_clear(err);
>
> The doc of svn_error_purge_tracing(err) says err should *not* be cleared.
>
> <snip>
> /**
> * Purge from @a err and its child chain any links associated with
> * error tracing placeholders, and return the new top-level error
> * chain item. @a err should be considered unusable after passing
> * through this function, but should *not* be cleared (as the returned
> * error shares memory with @a err). @a err can be #SVN_NO_ERROR.
> *
> * @since New in 1.7.
> */
> svn_error_t *svn_error_purge_tracing(svn_error_t *err);
> </snip>
>
> Are you sure?
>
> With regards
> Kamesh Jayachandran
>
>
Re: svn commit: r1052817 -
/subversion/trunk/subversion/tests/libsvn_subr/error-test.c
Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
You're quoting an old version of the docstring.
Kamesh Jayachandran wrote on Sun, Dec 26, 2010 at 12:10:46 +0530:
> >+
> >+ err2 = svn_error_purge_tracing(err);
> >+ for (child = err2; child; child = child->child)
> >+ if (svn_error__is_tracing_link(child))
> >+ {
> >+ return svn_error_create(SVN_ERR_TEST_FAILED, err,
> >+ "Tracing link found after purging the "
> >+ "following chain:");
> >+ }
> >+
> >+ svn_error_clear(err);
>
> The doc of svn_error_purge_tracing(err) says err should *not* be cleared.
>
> <snip>
> /**
> * Purge from @a err and its child chain any links associated with
> * error tracing placeholders, and return the new top-level error
> * chain item. @a err should be considered unusable after passing
> * through this function, but should *not* be cleared (as the returned
> * error shares memory with @a err). @a err can be #SVN_NO_ERROR.
> *
> * @since New in 1.7.
> */
> svn_error_t *svn_error_purge_tracing(svn_error_t *err);
> </snip>
>
> Are you sure?
>
> With regards
> Kamesh Jayachandran
>
>