You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Branko Čibej <br...@xbc.nu> on 2002/07/02 18:08:21 UTC
Re: svn commit: rev 2392 - trunk/subversion/mod_dav_svn
striker@tigris.org wrote:
>Author: striker
>Date: Tue, 02 Jul 2002 06:16:08 -0500
>New Revision: 2392
>
>Modified:
> trunk/subversion/mod_dav_svn/repos.c
>Log:
>* subversion/mod_dav_svn/repos.c
>
> (dav_svn_deliver): Make the autoindex look just a tiny bit nicer
> by not escaping the parts visible to the user.
>
>
>Modified: trunk/subversion/mod_dav_svn/repos.c
>==============================================================================
>--- trunk/subversion/mod_dav_svn/repos.c (original)
>+++ trunk/subversion/mod_dav_svn/repos.c Tue Jul 2 06:16:14 2002
>@@ -1521,7 +1521,7 @@
> if (resource->info->repos_path == NULL)
> title = "unknown location";
> else
>- title = ap_escape_uri(resource->pool, resource->info->repos_path);
>+ title = resource->info->repos_path;
>
> if (SVN_IS_VALID_REVNUM(resource->info->root.rev))
> title = apr_psprintf(resource->pool,
>@@ -1593,20 +1593,20 @@
> (void) svn_fs_is_dir(&is_dir, resource->info->root.root,
> entry_path, entry_pool);
>
>- name = ap_escape_uri(entry_pool, item->key);
>-
>+ name = item->key;
>+
> /* append a trailing slash onto the name for directories. we NEED
> this for the href portion so that the relative reference will
> descend properly. for the visible portion, it is just nice. */
> if (is_dir)
>- href = apr_pstrcat(entry_pool, name, "/", NULL);
>- else
>- href = name;
>+ name = apr_pstrcat(entry_pool, name, "/", NULL);
>+
>+ href = ap_escape_uri(entry_pool, name);
>
This bit is wrong. 'href' must end in a / if it represents a directory,
and 'name' must _not_ end in a slash if we're generating XML output.
>
> if (gen_html)
> ap_fprintf(output, bb,
> " <li><a href=\"%s\">%s</a></li>\n",
>- href, href);
>+ href, name);
> else
> {
> const char *const tag = (is_dir ? "dir" : "file");
>
>
--
Brane Čibej <br...@xbc.nu> http://www.xbc.nu/brane/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
RE: svn commit: rev 2392 - trunk/subversion/mod_dav_svn
Posted by Sander Striker <st...@apache.org>.
> From: Branko Cibej [mailto:brane@xbc.nu]
> Sent: 02 July 2002 20:08
>>Author: striker
>>Date: Tue, 02 Jul 2002 06:16:08 -0500
>>New Revision: 2392
>>
>>Modified:
>> trunk/subversion/mod_dav_svn/repos.c
>>Log:
>>* subversion/mod_dav_svn/repos.c
>>
>> (dav_svn_deliver): Make the autoindex look just a tiny bit nicer
>> by not escaping the parts visible to the user.
[...]
> This bit is wrong. 'href' must end in a / if it represents a directory,
> and 'name' must _not_ end in a slash if we're generating XML output.
Fixed in rev 2401.
Sander
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org