subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stef...@apache.org
Subject svn commit: r1616598 - in /subversion/trunk/subversion/libsvn_fs_x: index.c noderevs.c
Date Thu, 07 Aug 2014 21:24:23 GMT
Author: stefan2
Date: Thu Aug  7 21:24:22 2014
New Revision: 1616598

URL: http://svn.apache.org/r1616598
Log:
Fix / silence a few integer conversion warnings in FSX.

* subversion/libsvn_fs_x/index.c
  (l2p_proto_index_lookup): Remove unnecessary cast.

* subversion/libsvn_fs_x/noderevs.c
  (svn_fs_x__read_noderevs_container): Cast to entry counts to APR index type.
                                       Since the size of the whole container
                                       is limited to a few MB, there is no way
                                       to have more than 2G entries in it.

Modified:
    subversion/trunk/subversion/libsvn_fs_x/index.c
    subversion/trunk/subversion/libsvn_fs_x/noderevs.c

Modified: subversion/trunk/subversion/libsvn_fs_x/index.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_x/index.c?rev=1616598&r1=1616597&r2=1616598&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_x/index.c (original)
+++ subversion/trunk/subversion/libsvn_fs_x/index.c Thu Aug  7 21:24:22 2014
@@ -1638,7 +1638,7 @@ l2p_proto_index_lookup(apr_off_t *offset
       if (!eof && entry.item_index == item_index)
         {
           *offset = (apr_off_t)entry.offset - 1;
-          *sub_item = (apr_off_t)entry.sub_item;
+          *sub_item = entry.sub_item;
           break;
         }
     }

Modified: subversion/trunk/subversion/libsvn_fs_x/noderevs.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_fs_x/noderevs.c?rev=1616598&r1=1616597&r2=1616598&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_fs_x/noderevs.c (original)
+++ subversion/trunk/subversion/libsvn_fs_x/noderevs.c Thu Aug  7 21:24:22 2014
@@ -740,7 +740,7 @@ svn_fs_x__read_noderevs_container(svn_fs
   count
     = svn_packed__int_count(svn_packed__first_int_substream(ids_stream));
   noderevs->ids
-    = apr_array_make(result_pool, count, sizeof(binary_id_t));
+    = apr_array_make(result_pool, (int)count, sizeof(binary_id_t));
   for (i = 0; i < count; ++i)
     {
       binary_id_t id;
@@ -765,7 +765,7 @@ svn_fs_x__read_noderevs_container(svn_fs
   count
     = svn_packed__int_count(svn_packed__first_int_substream(noderevs_stream));
   noderevs->noderevs
-    = apr_array_make(result_pool, count, sizeof(binary_noderev_t));
+    = apr_array_make(result_pool, (int)count, sizeof(binary_noderev_t));
   for (i = 0; i < count; ++i)
     {
       binary_noderev_t noderev;



Mime
View raw message