You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by da...@apache.org on 2012/02/29 11:25:52 UTC
svn commit: r1295055 - /subversion/trunk/subversion/libsvn_ra_serf/locks.c
Author: danielsh
Date: Wed Feb 29 10:25:51 2012
New Revision: 1295055
URL: http://svn.apache.org/viewvc?rev=1295055&view=rev
Log:
Eliminate a compiler warning.
(The code on 1.7.x names the outer variable differently, thus avoiding
the warning.)
* subversion/libsvn_ra_serf/locks.c
(svn_ra_serf__unlock):
Tweak the logic flow to avoid variable shadowing. This was
harmless due to an unconditional 'continue;' statement in the
block that declares the shadowing variable.
Modified:
subversion/trunk/subversion/libsvn_ra_serf/locks.c
Modified: subversion/trunk/subversion/libsvn_ra_serf/locks.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra_serf/locks.c?rev=1295055&r1=1295054&r2=1295055&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra_serf/locks.c (original)
+++ subversion/trunk/subversion/libsvn_ra_serf/locks.c Wed Feb 29 10:25:51 2012
@@ -716,8 +716,6 @@ svn_ra_serf__unlock(svn_ra_session_t *ra
token = existing_lock->token;
if (!token)
{
- svn_error_t *err;
-
err = svn_error_createf(SVN_ERR_RA_NOT_LOCKED, NULL,
_("'%s' is not locked in the repository"),
path);
@@ -728,11 +726,15 @@ svn_ra_serf__unlock(svn_ra_session_t *ra
err2 = lock_func(lock_baton, path, FALSE, NULL, err,
iterpool);
svn_error_clear(err);
+ err = NULL;
if (err2)
return svn_error_trace(err2);
}
else
- svn_error_clear(err);
+ {
+ svn_error_clear(err);
+ err = NULL;
+ }
continue;
}
}