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

Re: [PATCH] Repository root relative url support in svn CLI -- REDUX

From: Troy Curtis Jr <troycurtisjr_at_gmail.com>
Date: Wed, 27 Feb 2008 21:33:44 -0600

On Wed, Feb 27, 2008 at 6:38 AM, Arfrever Frehtes Taifersar Arahesis
<arfrever.fta_at_gmail.com> wrote:
> 2008-02-27 05:01 Troy Curtis Jr <troycurtisjr_at_gmail.com> napisał(a):
>
> > Index: subversion/svn/cl.h
> > ==================================================================
> > --- subversion/svn/cl.h (revision 29570)
>
> > +++ subversion/svn/cl.h (working copy)
> > @@ -555,7 +555,48 @@
> > "file" or, in any other case, the empty string. */
>
> > const char *svn_cl__node_kind_str(svn_node_kind_t kind);
> >
> > +/*
> > + * Return true iff URL is a relative URL. Specifically that it starts
> > + * with the characters "^/".
> > + */
> > +svn_boolean_t svn_cl__is_relative_url(const char *url);
>
> svn_boolean_t
> svn_cl__is_relative_url(const char *url);
>

In fairness it fits in better with that file the way I had it :)

>
> > Index: subversion/svn/util.c
> > ==================================================================
> > --- subversion/svn/util.c (revision 29570)
>
> > +++ subversion/svn/util.c (working copy)
> > ...
> > +svn_boolean_t
> > +svn_cl__is_relative_url(const char *url)
> > +{
> >
> > + return(strncmp("^/", url, 2) ? FALSE : TRUE);
> > +}
>
> Wrong indentation.
>
> > svn_error_t *
> > +svn_cl__resolve_relative_url(const char **absolute_url,
>
> Wrong indentation in whole this function.
>
>
> > + else if ( (root_url != NULL)
> > + && (strcmp(root_url, tmp_root_url) != 0))
> > + return svn_error_createf(SVN_ERR_ILLEGAL_TARGET, NULL,
> > + _("All non-relative targets must have the same root url."));
>
> > + else
> > + root_url = tmp_root_url;
> > + }
> > +
> > + /*
> > + * Use the current directory's root url if one wasn't found using the
> > + * arguments.
> > + */
> > + if (root_url == NULL)
> > + {
> > + if ((error = svn_client_root_url_from_path(&root_url,
> > + svn_path_canonicalize(".", pool),
> > + ctx, pool)))
> > + return error;
> > + }
>
> Wrong indentation.
>

Not only that, but that is what the SVN_ERR() macro is for!

> --
> Arfrever Frehtes Taifersar Arahesis
>

Thanks for you comments!

-- 
"Beware of spyware. If you can, use the Firefox browser." - USA Today
Download now at http://getfirefox.com
Registered Linux User #354814 ( http://counter.li.org/)
Received on 2008-02-28 04:33:56 CET

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