You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2012/07/04 20:05:52 UTC

svn commit: r1357355 - /subversion/trunk/subversion/svn/notify.c

Author: stsp
Date: Wed Jul  4 18:05:51 2012
New Revision: 1357355

URL: http://svn.apache.org/viewvc?rev=1357355&view=rev
Log:
* subversion/svn/notify.c
  (svn_cl__notifier_get_conflicted_paths): Return a proper result array
   containing const char * paths instead elements of the wrong type
   svn_sort__item_t.

Modified:
    subversion/trunk/subversion/svn/notify.c

Modified: subversion/trunk/subversion/svn/notify.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/notify.c?rev=1357355&r1=1357354&r2=1357355&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/notify.c (original)
+++ subversion/trunk/subversion/svn/notify.c Wed Jul  4 18:05:51 2012
@@ -1119,8 +1119,23 @@ apr_array_header_t *
 svn_cl__notifier_get_conflicted_paths(void *baton, apr_pool_t *result_pool)
 {
   struct notify_baton *nb = baton;
+  apr_array_header_t *sorted_array;
+  apr_array_header_t *result_array;
+  int i;
 
-  return svn_sort__hash(nb->conflicted_paths,
-                        svn_sort_compare_items_as_paths,
-                        result_pool);
+  sorted_array = svn_sort__hash(nb->conflicted_paths,
+                                svn_sort_compare_items_as_paths,
+                                apr_hash_pool_get(nb->conflicted_paths));
+  result_array = apr_array_make(result_pool, sorted_array->nelts,
+                                sizeof(const char *));
+  for (i = 0; i < sorted_array->nelts; i++)
+    {
+      svn_sort__item_t item;
+      
+      item = APR_ARRAY_IDX(sorted_array, i, svn_sort__item_t);
+      APR_ARRAY_PUSH(result_array, const char *) = apr_pstrdup(result_pool,
+                                                               item.key);
+    }
+
+  return result_array;
 }