subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From br...@apache.org
Subject svn commit: r1785319 - in /subversion/trunk/subversion: include/svn_client.h include/svn_ra.h include/svn_repos.h libsvn_client/list.c libsvn_ra/ra_loader.c libsvn_ra/ra_loader.h libsvn_ra_local/ra_plugin.c libsvn_ra_svn/client.c libsvn_repos/list.c
Date Fri, 03 Mar 2017 15:08:28 GMT
Author: brane
Date: Fri Mar  3 15:08:28 2017
New Revision: 1785319

URL: http://svn.apache.org/viewvc?rev=1785319&view=rev
Log:
Fix design bug in svn_client_list4()/svn_ra_list()/svn_repos_list() APIs.

* subversion/include/svn_client.h (svn_client_list4):
   Make the patterns array const. All dependencies and references updated.
* subversion/include/svn_ra.h (svn_ra_list): Likewise.
* subversion/include/svn_repos.h (svn_repos_list): Likewise.

* subversion/libsvn_client/list.c
  (list_externals, list_internal, match_patterns,
   get_dir_contents, list_external_items, svn_client_list4):
   Make patterns array const.

* subversion/libsvn_ra/ra_loader.h (svn_ra__vtable_t::list): Likewise.
* subversion/libsvn_ra/ra_loader.c (svn_ra_list): Likewise.
* subversion/libsvn_ra_local/ra_plugin.c (svn_ra_local__list): Likewise.
* subversion/libsvn_ra_svn/client.c (ra_svn_list): And again.
* subversion/libsvn_repos/list.c (matches_any, do_list, svn_repos_list):
   And some more of the same.

Modified:
    subversion/trunk/subversion/include/svn_client.h
    subversion/trunk/subversion/include/svn_ra.h
    subversion/trunk/subversion/include/svn_repos.h
    subversion/trunk/subversion/libsvn_client/list.c
    subversion/trunk/subversion/libsvn_ra/ra_loader.c
    subversion/trunk/subversion/libsvn_ra/ra_loader.h
    subversion/trunk/subversion/libsvn_ra_local/ra_plugin.c
    subversion/trunk/subversion/libsvn_ra_svn/client.c
    subversion/trunk/subversion/libsvn_repos/list.c

Modified: subversion/trunk/subversion/include/svn_client.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_client.h?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_client.h (original)
+++ subversion/trunk/subversion/include/svn_client.h Fri Mar  3 15:08:28 2017
@@ -6464,7 +6464,7 @@ typedef svn_error_t *(*svn_client_list_f
  * its children.  If @a path_or_url is non-existent, return
  * #SVN_ERR_FS_NOT_FOUND.
  *
- * If the @a pattern array of <tt>const char *</tt> is not @c NULL, only
+ * If the @a patterns array of <tt>const char *</tt> is not @c NULL, only
  * report paths whose last segment matches one of the specified glob
  * patterns.  This does not affect the size of the tree nor the number of
  * externals being covered.
@@ -6497,7 +6497,7 @@ svn_error_t *
 svn_client_list4(const char *path_or_url,
                  const svn_opt_revision_t *peg_revision,
                  const svn_opt_revision_t *revision,
-                 apr_array_header_t *patterns,
+                 const apr_array_header_t *patterns,
                  svn_depth_t depth,
                  apr_uint32_t dirent_fields,
                  svn_boolean_t fetch_locks,

Modified: subversion/trunk/subversion/include/svn_ra.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_ra.h?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_ra.h (original)
+++ subversion/trunk/subversion/include/svn_ra.h Fri Mar  3 15:08:28 2017
@@ -1186,7 +1186,7 @@ svn_error_t *
 svn_ra_list(svn_ra_session_t *session,
             const char *path,
             svn_revnum_t revision,
-            apr_array_header_t *patterns,
+            const apr_array_header_t *patterns,
             svn_depth_t depth,
             apr_uint32_t dirent_fields,
             svn_ra_dirent_receiver_t receiver,

Modified: subversion/trunk/subversion/include/svn_repos.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_repos.h?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_repos.h (original)
+++ subversion/trunk/subversion/include/svn_repos.h Fri Mar  3 15:08:28 2017
@@ -1759,7 +1759,7 @@ typedef svn_error_t *(* svn_repos_dirent
 svn_error_t *
 svn_repos_list(svn_fs_root_t *root,
                const char *path,
-               apr_array_header_t *patterns,
+               const apr_array_header_t *patterns,
                svn_depth_t depth,
                svn_boolean_t path_info_only,
                svn_repos_authz_func_t authz_read_func,

Modified: subversion/trunk/subversion/libsvn_client/list.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/list.c?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/list.c (original)
+++ subversion/trunk/subversion/libsvn_client/list.c Fri Mar  3 15:08:28 2017
@@ -43,7 +43,7 @@
 /* Prototypes for referencing before declaration */
 static svn_error_t *
 list_externals(apr_hash_t *externals,
-               apr_array_header_t *patterns,
+               const apr_array_header_t *patterns,
                svn_depth_t depth,
                apr_uint32_t dirent_fields,
                svn_boolean_t fetch_locks,
@@ -56,7 +56,7 @@ static svn_error_t *
 list_internal(const char *path_or_url,
               const svn_opt_revision_t *peg_revision,
               const svn_opt_revision_t *revision,
-              apr_array_header_t *patterns,
+              const apr_array_header_t *patterns,
               svn_depth_t depth,
               apr_uint32_t dirent_fields,
               svn_boolean_t fetch_locks,
@@ -72,7 +72,7 @@ list_internal(const char *path_or_url,
  * Note that any S will match if PATTERNS is empty. */
 static svn_boolean_t
 match_patterns(const char *s,
-               apr_array_header_t *patterns)
+               const apr_array_header_t *patterns)
 {
   int i;
   if (!patterns)
@@ -121,7 +121,7 @@ get_dir_contents(apr_uint32_t dirent_fie
                  svn_ra_session_t *ra_session,
                  apr_hash_t *locks,
                  const char *fs_path,
-                 apr_array_header_t *patterns,
+                 const apr_array_header_t *patterns,
                  svn_depth_t depth,
                  svn_client_ctx_t *ctx,
                  apr_hash_t *externals,
@@ -310,7 +310,7 @@ static svn_error_t *
 list_internal(const char *path_or_url,
               const svn_opt_revision_t *peg_revision,
               const svn_opt_revision_t *revision,
-              apr_array_header_t *patterns,
+              const apr_array_header_t *patterns,
               svn_depth_t depth,
               apr_uint32_t dirent_fields,
               svn_boolean_t fetch_locks,
@@ -451,7 +451,7 @@ wrap_list_error(const svn_client_ctx_t *
 static svn_error_t *
 list_external_items(apr_array_header_t *external_items,
                     const char *externals_parent_url,
-                    apr_array_header_t *patterns,
+                    const apr_array_header_t *patterns,
                     svn_depth_t depth,
                     apr_uint32_t dirent_fields,
                     svn_boolean_t fetch_locks,
@@ -515,7 +515,7 @@ list_external_items(apr_array_header_t *
    passed to svn_client_list(). */
 static svn_error_t *
 list_externals(apr_hash_t *externals,
-               apr_array_header_t *patterns,
+               const apr_array_header_t *patterns,
                svn_depth_t depth,
                apr_uint32_t dirent_fields,
                svn_boolean_t fetch_locks,
@@ -561,7 +561,7 @@ svn_error_t *
 svn_client_list4(const char *path_or_url,
                  const svn_opt_revision_t *peg_revision,
                  const svn_opt_revision_t *revision,
-                 apr_array_header_t *patterns,
+                 const apr_array_header_t *patterns,
                  svn_depth_t depth,
                  apr_uint32_t dirent_fields,
                  svn_boolean_t fetch_locks,

Modified: subversion/trunk/subversion/libsvn_ra/ra_loader.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra/ra_loader.c?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra/ra_loader.c (original)
+++ subversion/trunk/subversion/libsvn_ra/ra_loader.c Fri Mar  3 15:08:28 2017
@@ -649,7 +649,7 @@ svn_error_t *
 svn_ra_list(svn_ra_session_t *session,
             const char *path,
             svn_revnum_t revision,
-            apr_array_header_t *patterns,
+            const apr_array_header_t *patterns,
             svn_depth_t depth,
             apr_uint32_t dirent_fields,
             svn_ra_dirent_receiver_t receiver,

Modified: subversion/trunk/subversion/libsvn_ra/ra_loader.h
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra/ra_loader.h?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra/ra_loader.h (original)
+++ subversion/trunk/subversion/libsvn_ra/ra_loader.h Fri Mar  3 15:08:28 2017
@@ -336,7 +336,7 @@ typedef struct svn_ra__vtable_t {
   svn_error_t *(*list)(svn_ra_session_t *session,
                        const char *path,
                        svn_revnum_t revision,
-                       apr_array_header_t *patterns,
+                       const apr_array_header_t *patterns,
                        svn_depth_t depth,
                        apr_uint32_t dirent_fields,
                        svn_ra_dirent_receiver_t receiver,

Modified: subversion/trunk/subversion/libsvn_ra_local/ra_plugin.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra_local/ra_plugin.c?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra_local/ra_plugin.c (original)
+++ subversion/trunk/subversion/libsvn_ra_local/ra_plugin.c Fri Mar  3 15:08:28 2017
@@ -1837,7 +1837,7 @@ static svn_error_t *
 svn_ra_local__list(svn_ra_session_t *session,
                    const char *path,
                    svn_revnum_t revision,
-                   apr_array_header_t *patterns,
+                   const apr_array_header_t *patterns,
                    svn_depth_t depth,
                    apr_uint32_t dirent_fields,
                    svn_ra_dirent_receiver_t receiver,

Modified: subversion/trunk/subversion/libsvn_ra_svn/client.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_ra_svn/client.c?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_ra_svn/client.c (original)
+++ subversion/trunk/subversion/libsvn_ra_svn/client.c Fri Mar  3 15:08:28 2017
@@ -3131,7 +3131,7 @@ static svn_error_t *
 ra_svn_list(svn_ra_session_t *session,
             const char *path,
             svn_revnum_t revision,
-            apr_array_header_t *patterns,
+            const apr_array_header_t *patterns,
             svn_depth_t depth,
             apr_uint32_t dirent_fields,
             svn_ra_dirent_receiver_t receiver,

Modified: subversion/trunk/subversion/libsvn_repos/list.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_repos/list.c?rev=1785319&r1=1785318&r2=1785319&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_repos/list.c (original)
+++ subversion/trunk/subversion/libsvn_repos/list.c Fri Mar  3 15:08:28 2017
@@ -94,7 +94,7 @@ svn_repos_stat(svn_dirent_t **dirent,
  * Note that any DIRNAME will match if PATTERNS is empty. */
 static svn_boolean_t
 matches_any(const char *dirname,
-            apr_array_header_t *patterns)
+            const apr_array_header_t *patterns)
 {
   int i;
   if (!patterns)
@@ -170,7 +170,7 @@ compare_filtered_dirent(const void *lhs,
 static svn_error_t *
 do_list(svn_fs_root_t *root,
         const char *path,
-        apr_array_header_t *patterns,
+        const apr_array_header_t *patterns,
         svn_depth_t depth,
         svn_boolean_t path_info_only,
         svn_repos_authz_func_t authz_read_func,
@@ -269,7 +269,7 @@ do_list(svn_fs_root_t *root,
 svn_error_t *
 svn_repos_list(svn_fs_root_t *root,
                const char *path,
-               apr_array_header_t *patterns,
+               const apr_array_header_t *patterns,
                svn_depth_t depth,
                svn_boolean_t path_info_only,
                svn_repos_authz_func_t authz_read_func,



Mime
View raw message