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

Re: Possible bug in SVNAdmin.cpp/setLog API?

From: Malcolm Rowe <malcolm-svn-dev_at_farside.org.uk>
Date: 2006-01-09 14:22:08 CET

On Mon, Jan 02, 2006 at 12:49:57PM -0500, Wascally Wabbit wrote:
> As per the FAQ on filing bugs/issues...I'm trying to use SVNAdmin.setLog
> via the Java JNI libraries. There seems to be a no-win condition at lines
> 581-595 in SVNAdmin.cpp in trunk.
>
> if (revision.revision()->kind != svn_opt_revision_number)
> {
> JNIUtil::handleSVNError(
> svn_error_createf (SVN_ERR_CL_ARG_PARSING_ERROR, NULL,
> _("Missing revision")));
> return;
> }
> else if (revision.revision()->kind != svn_opt_revision_unspecified)
> {
> JNIUtil::handleSVNError(
> svn_error_createf (SVN_ERR_CL_ARG_PARSING_ERROR, NULL,
> _("Only one revision allowed")));
> return;
> }
>
> If I pass the first if-clause that means kind == svn_opt_revision_number
> which
> means the subsequent else-if clause will ALWAYS fail (kind is an enum).
>
> Seems like a bug to me...
>

Yes, that looks like a bug to me too. Unfortunately, it's not immediately
obvious to me what the correct code should be. Patrick may know, since
he wrote the code originally, so cc'd.

Regards,
Malcolm

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Jan 9 14:33:48 2006

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