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

Re: No error dialog if lock command failed

From: Mark Phippard <MarkP_at_softlanding.com>
Date: 2005-08-30 16:00:59 CEST

Thanks. JavaHL is not part of Subclipse, it is part of Subversion. They
have info about how to send them a patch here:

http://subversion.tigris.org/mailing-list-guidelines.html#patches

Mark

Andriy Kulchytskyy <whoops@ukrtop.com> wrote on 08/30/2005 10:21:56 AM:

> There is no error dialog (and no exception thrown) if lock command
> failed. Using JavaHL interface.
>
> Probably bug is in JavaHL library.
> File: http://svn.collab.
> net/repos/svn/trunk/subversion/bindings/java/javahl/native/SVNClient.cpp
> Method: SVNClient::lock (line 3072)
>
> 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(); // one *Err
variable
> if(Err != NULL)
> {
> JNIUtil::handleSVNError(Err);
> return;
> }
> apr_pool_t * apr_pool = requestPool.pool ();
> svn_client_ctx_t *ctx = getContext(NULL);
> svn_error_t *err = svn_client_lock(targetsApr, // !!! another
*err variable
> comment, force, ctx, apr_pool);
>
> if (Err != NULL) // !!! but checked
the first one
> {
> JNIUtil::handleSVNError(err);
> }
> }
>
> The correct code should be:
>
> 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);
> }
> }

_____________________________________________________________________________
Scanned for SoftLanding Systems, Inc. by IBM Email Security Management Services powered by MessageLabs.
_____________________________________________________________________________
Received on Wed Aug 31 00:00:59 2005

This is an archived mail posted to the Subclipse Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.