subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From phi...@apache.org
Subject svn commit: r1466830 - in /subversion/trunk/subversion/libsvn_subr: deprecated.c subst.c
Date Thu, 11 Apr 2013 10:35:35 GMT
Author: philip
Date: Thu Apr 11 10:35:34 2013
New Revision: 1466830

URL: http://svn.apache.org/r1466830
Log:
* subversion/libsvn_subr/subst.c
  (svn_subst_build_keywords): Move deprecated function ...

* subversion/libsvn_subr/deprecated.c
  (svn_subst_build_keywords): ... here.

Modified:
    subversion/trunk/subversion/libsvn_subr/deprecated.c
    subversion/trunk/subversion/libsvn_subr/subst.c

Modified: subversion/trunk/subversion/libsvn_subr/deprecated.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/deprecated.c?rev=1466830&r1=1466829&r2=1466830&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_subr/deprecated.c (original)
+++ subversion/trunk/subversion/libsvn_subr/deprecated.c Thu Apr 11 10:35:34 2013
@@ -1234,3 +1234,48 @@ svn_utf_initialize(apr_pool_t *pool)
 {
   svn_utf_initialize2(pool, FALSE);
 }
+
+svn_error_t *
+svn_subst_build_keywords(svn_subst_keywords_t *kw,
+                         const char *keywords_val,
+                         const char *rev,
+                         const char *url,
+                         apr_time_t date,
+                         const char *author,
+                         apr_pool_t *pool)
+{
+  apr_hash_t *kwhash;
+  const svn_string_t *val;
+
+  SVN_ERR(svn_subst_build_keywords2(&kwhash, keywords_val, rev,
+                                    url, date, author, pool));
+
+  /* The behaviour of pre-1.3 svn_subst_build_keywords, which we are
+   * replicating here, is to write to a slot in the svn_subst_keywords_t
+   * only if the relevant keyword was present in keywords_val, otherwise
+   * leaving that slot untouched. */
+
+  val = svn_hash_gets(kwhash, SVN_KEYWORD_REVISION_LONG);
+  if (val)
+    kw->revision = val;
+
+  val = svn_hash_gets(kwhash, SVN_KEYWORD_DATE_LONG);
+  if (val)
+    kw->date = val;
+
+  val = svn_hash_gets(kwhash, SVN_KEYWORD_AUTHOR_LONG);
+  if (val)
+    kw->author = val;
+
+  val = svn_hash_gets(kwhash, SVN_KEYWORD_URL_LONG);
+  if (val)
+    kw->url = val;
+
+  val = svn_hash_gets(kwhash, SVN_KEYWORD_ID);
+  if (val)
+    kw->id = val;
+
+  return SVN_NO_ERROR;
+}
+
+

Modified: subversion/trunk/subversion/libsvn_subr/subst.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_subr/subst.c?rev=1466830&r1=1466829&r2=1466830&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_subr/subst.c (original)
+++ subversion/trunk/subversion/libsvn_subr/subst.c Thu Apr 11 10:35:34 2013
@@ -276,49 +276,6 @@ keyword_printf(const char *fmt,
   return svn_stringbuf__morph_into_string(value);
 }
 
-svn_error_t *
-svn_subst_build_keywords(svn_subst_keywords_t *kw,
-                         const char *keywords_val,
-                         const char *rev,
-                         const char *url,
-                         apr_time_t date,
-                         const char *author,
-                         apr_pool_t *pool)
-{
-  apr_hash_t *kwhash;
-  const svn_string_t *val;
-
-  SVN_ERR(svn_subst_build_keywords2(&kwhash, keywords_val, rev,
-                                    url, date, author, pool));
-
-  /* The behaviour of pre-1.3 svn_subst_build_keywords, which we are
-   * replicating here, is to write to a slot in the svn_subst_keywords_t
-   * only if the relevant keyword was present in keywords_val, otherwise
-   * leaving that slot untouched. */
-
-  val = svn_hash_gets(kwhash, SVN_KEYWORD_REVISION_LONG);
-  if (val)
-    kw->revision = val;
-
-  val = svn_hash_gets(kwhash, SVN_KEYWORD_DATE_LONG);
-  if (val)
-    kw->date = val;
-
-  val = svn_hash_gets(kwhash, SVN_KEYWORD_AUTHOR_LONG);
-  if (val)
-    kw->author = val;
-
-  val = svn_hash_gets(kwhash, SVN_KEYWORD_URL_LONG);
-  if (val)
-    kw->url = val;
-
-  val = svn_hash_gets(kwhash, SVN_KEYWORD_ID);
-  if (val)
-    kw->id = val;
-
-  return SVN_NO_ERROR;
-}
-
 static svn_error_t *
 build_keywords(apr_hash_t **kw,
                svn_boolean_t expand_custom_keywords,



Mime
View raw message