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

Re: svn commit: r1137927 - in /subversion/trunk/subversion: libsvn_subr/dirent_uri.c tests/libsvn_subr/dirent_uri-test.c

From: Stefan Sperling <stsp_at_elego.de>
Date: Tue, 21 Jun 2011 12:19:14 +0200

On Tue, Jun 21, 2011 at 10:13:16AM -0000, rhuijben_at_apache.org wrote:
> Author: rhuijben
> Date: Tue Jun 21 10:13:16 2011
> New Revision: 1137927
>
> URL: http://svn.apache.org/viewvc?rev=1137927&view=rev
> Log:
> A canonical url to a http:, https: and svn: repository shouldn't contain the
> default port number. With a default port number it is a valid url, but it is
> not canonical.
>
> Make svn_uri_canonicalize remove default port numbers and svn_is_canonicalize
> return false on uris with invalid and/or default port numbers.
 
> + if (port == 80 && strncmp(uri, "http:", 5) == 0)
> + return FALSE;
> + else if (port == 443 && !strncmp(uri, "https:", 6) == 0)
> + return FALSE;
> + else if (port == 3690 && !strncmp(uri, "svn:", 4) == 0)
> + return FALSE;

This breaks e.g. running svnserve on port 80.
I don't think it's a good idea to assume that people aren't going to
run some service on the default port of another service.
Port numbers are conventions, not hard rules.
Received on 2011-06-21 12:19:51 CEST

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.