subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhuij...@apache.org
Subject svn commit: r1340515 - /subversion/trunk/subversion/libsvn_subr/io.c
Date Sat, 19 May 2012 16:45:46 GMT
Author: rhuijben
Date: Sat May 19 16:45:45 2012
New Revision: 1340515

URL: http://svn.apache.org/viewvc?rev=1340515&view=rev
Log:
Tweak performance of a simple io function, to hide it from my performance
analyzer.

* subversion/libsvn_subr/io.c
  (entry_name_to_utf8): Apply the same optimization as inside cstring_to_utf8,
    just make sure the values is copied as that is the reason we can't use
    that function here.

Modified:
    subversion/trunk/subversion/libsvn_subr/io.c

Modified: subversion/trunk/subversion/libsvn_subr/io.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/io.c?rev=1340515&r1=1340514&r2=1340515&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_subr/io.c (original)
+++ subversion/trunk/subversion/libsvn_subr/io.c Sat May 19 16:45:45 2012
@@ -229,6 +229,10 @@ entry_name_to_utf8(const char **name_p,
                    const char *parent,
                    apr_pool_t *pool)
 {
+#if defined(WIN32) || defined(DARWIN)
+  *name_p = apr_pstrdup(pool, name);
+  return SVN_NO_ERROR;
+#else
   svn_error_t *err = svn_path_cstring_to_utf8(name_p, name, pool);
   if (err && err->apr_err == APR_EINVAL)
     {
@@ -238,6 +242,7 @@ entry_name_to_utf8(const char **name_p,
                                svn_dirent_local_style(parent, pool));
     }
   return err;
+#endif
 }
 
 



Mime
View raw message