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

Re: svn commit: r11599 - in trunk/subversion: clients/cmdline include

From: <kfogel_at_collab.net>
Date: 2004-10-25 16:18:35 CEST

jpieper@tigris.org writes:
> --- trunk/subversion/clients/cmdline/log-cmd.c
> +++ trunk/subversion/clients/cmdline/log-cmd.c
> @@ -495,6 +497,27 @@
> opt_state->end_revision.kind = svn_opt_revision_number;
> opt_state->end_revision.value.number = 1; /* oldest commit */
> }
> + }
> +
> + /* Verify that we pass at most one working copy path. */
> + target = APR_ARRAY_IDX (targets, 0, const char *);
> +
> + if (! svn_path_is_url (target) )
> + {
> + if (targets->nelts > 1)
> + return svn_error_create (SVN_ERR_UNSUPPORTED_FEATURE, NULL,
> + _("When specifying working copy paths, only "
> + "one target may be given"));
> + } else {
> + /* Check to make sure there are no other URLs. */
> + for (i = 1; i < targets->nelts; i++) {
> + target = APR_ARRAY_IDX (targets, 1, const char *);
> +
> + if (svn_path_is_url (target))
> + return svn_error_create (SVN_ERR_UNSUPPORTED_FEATURE, NULL,
> + _("Only relative paths can be specified "
> + "after a URL"));
> + }

We avoid the "cuddled-else" style, in favor of:

   if (cond)
     {
       ...
     }
   else
     {
       ...
     }

> --- trunk/subversion/include/svn_client.h (original)
> +++ trunk/subversion/include/svn_client.h Sat Oct 23 12:32:03 2004
> @@ -724,13 +724,12 @@
> * start to @a end in turn, inclusive (but never invoke @a receiver on a
> * given log message more than once).
> *
> - * @a targets contains all the working copy paths (as <tt>const char
> - * *</tt>'s) for which log messages are desired. The repository info is
> + * @a targets contains either a URL followed by zero or more relative
> + * paths, or a list working copy paths (as <tt> const char *</tt>'s
                     ^^^

Missing "of". Also, should be no space between opening "<tt>" tag and
the first word inside it, I think, though I'm not sure it would matter
much in output.

> + * for which log messages are desired. The repository info is
> * determined by taking the common prefix of the target entries' URLs.
> - * @a receiver is invoked only on messages
> - * whose revisions involved a change to some path in @a targets.
> - *
> - * ### todo: the above paragraph is not fully implemented yet.
> + * @a receiver is invoked only on messages whose revisions involved a
> + * change to some path in @a targets.

Did you mean to eliminate a blank line there?

The change itself looks great, btw.

-K

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Oct 25 18:10:32 2004

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.