You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by rh...@apache.org on 2013/10/31 10:39:52 UTC

svn commit: r1537415 - /subversion/trunk/subversion/mod_dav_svn/mod_dav_svn.c

Author: rhuijben
Date: Thu Oct 31 09:39:51 2013
New Revision: 1537415

URL: http://svn.apache.org/r1537415
Log:
Following up on r1537360, construct the bogus path in a different format to
avoid assertions in the dirent functions on Windows on repository paths that
can't be represented on disk.

* subversion/mod_dav_svn/mod_dav_svn.c
  (dav_svn__translate_name): Join components with '|'.

Modified:
    subversion/trunk/subversion/mod_dav_svn/mod_dav_svn.c

Modified: subversion/trunk/subversion/mod_dav_svn/mod_dav_svn.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/mod_dav_svn/mod_dav_svn.c?rev=1537415&r1=1537414&r2=1537415&view=diff
==============================================================================
--- subversion/trunk/subversion/mod_dav_svn/mod_dav_svn.c (original)
+++ subversion/trunk/subversion/mod_dav_svn/mod_dav_svn.c Thu Oct 31 09:39:51 2013
@@ -1137,10 +1137,18 @@ static int dav_svn__translate_name(reque
     repos_path++;
 
   /* Combine 'svn:', fs_path and repos_path to produce the bogus path we're
-   * placing in r->filename. */
-  r->filename = apr_pstrcat(r->pool, "svn:",
-                            svn_dirent_join(fs_path, repos_path, r->pool),
-                            NULL);
+   * placing in r->filename.
+   *
+   * fs_path is a dirent, but repos_path is a relpath. In general it is safe
+   * to join these, but when a path in a repository is 'trunk/c:hi' this
+   * results in a non canonical dirent on Windows, so we can't use standard
+   * helpers such as svn_dirent_join.
+   *
+   * As nobody should care about this path, just construct something simple
+   * that makes sense when a user reads it in the log file.
+   */
+  r->filename = apr_pstrcat(r->pool, 
+                            "svn:|", fs_path, "|", repos_path, SVN_VA_NULL);
 
   /* Leave a note to ourselves so that we know not to decline in the
    * map_to_storage hook. */