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

Re: [PATCH] No error dialog if lock command failed

From: Jani Averbach <jaa_at_jaa.iki.fi>
Date: 2005-08-31 21:12:30 CEST

On 2005-08-30 17:46+0200, Andriy Kulchytskyy wrote:
> Hello,

I have few very obvious comments about your patch:
 
> There is no error dialog (and no exception thrown) if lock command
> failed. I am using subclipse (JavaHL interface).
>
> Probably bug is in JavaHL library in file SVNClient.cpp
> http://svn.collab.net/repos/svn/trunk/subversion/bindings/java/javahl/native/SVNClient.cpp

Please don't paste original function code in to your message.

> The correct code should be:

Don't paste either changed function code in to your message, just
include your patch. And generate your patch from the top level of the
tree, so the full path to the file is visible.

>
> void SVNClient::lock(Targets &targets, const char *comment,
> bool force)
> {
> Pool requestPool;
> const apr_array_header_t *targetsApr = targets.array(requestPool);
> svn_error_t *Err = targets.error_occured();
> if(Err != NULL)
> {
> JNIUtil::handleSVNError(Err);
> return;
> }
> apr_pool_t * apr_pool = requestPool.pool ();
> svn_client_ctx_t *ctx = getContext(NULL);
> Err = svn_client_lock(targetsApr,
> comment, force, ctx, apr_pool);
>
> if (Err != NULL)
> {
> JNIUtil::handleSVNError(err);
> }
> }

Secondly, please test your changes before posting them, there are
"make check" and "make check-javahl" targets in the Makefile. Your
patch doesn't even compile, because err is undefined.

Thirdly, there is pretty thorough document how to hack subversion, and
howto submit patches, http://subversion.tigris.org/hacking.html

Please take look at least the following sections:
http://subversion.tigris.org/hacking.html#log-messages
http://subversion.tigris.org/hacking.html#patches

Then one thing more: Don't file issues if you are not asked to do that
on the mailing list. There is a huge yellow warning box which
explicitly told not to do that at the front page of the issue tracker
http://subversion.tigris.org/project_issues.html

What comes about actual change I think it is correct, however I can't
test it.

Would you like to post again your patch (by following Hacking guides) and
if you could write a regression test for this bug, it would be really
nice. This way we can ensure that the bug is actually fixed and stays
fixed. Thanks.

BR, Jani

-- 
Jani Averbach 
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Aug 31 21:13:33 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.