subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From svn-r...@apache.org
Subject svn commit: r1530852 - in /subversion/branches/1.8.x: ./ STATUS subversion/libsvn_client/mergeinfo.c
Date Thu, 10 Oct 2013 04:02:02 GMT
Author: svn-role
Date: Thu Oct 10 04:02:02 2013
New Revision: 1530852

URL: http://svn.apache.org/r1530852
Log:
Merge r1519955 from trunk:

 * r1519955
   Fix a segfault with 'svn mergeinfo'.
   Justification:
     Missing NULL pointer checks are bad, user complained.
   Votes:
     +1: stsp, rhuijben, stefan2

Modified:
    subversion/branches/1.8.x/   (props changed)
    subversion/branches/1.8.x/STATUS
    subversion/branches/1.8.x/subversion/libsvn_client/mergeinfo.c

Propchange: subversion/branches/1.8.x/
------------------------------------------------------------------------------
  Merged /subversion/trunk:r1519955

Modified: subversion/branches/1.8.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/STATUS?rev=1530852&r1=1530851&r2=1530852&view=diff
==============================================================================
--- subversion/branches/1.8.x/STATUS (original)
+++ subversion/branches/1.8.x/STATUS Thu Oct 10 04:02:02 2013
@@ -147,13 +147,6 @@ Veto-blocked changes:
 Approved changes:
 =================
 
- * r1519955
-   Fix a segfault with 'svn mergeinfo'.
-   Justification:
-     Missing NULL pointer checks are bad, user complained.
-   Votes:
-     +1: stsp, rhuijben, stefan2
-
  * r1520529, r1520532, r1520539
    Properly re-canonicalize urls read from xml based entries files.
    Justification:

Modified: subversion/branches/1.8.x/subversion/libsvn_client/mergeinfo.c
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/subversion/libsvn_client/mergeinfo.c?rev=1530852&r1=1530851&r2=1530852&view=diff
==============================================================================
--- subversion/branches/1.8.x/subversion/libsvn_client/mergeinfo.c (original)
+++ subversion/branches/1.8.x/subversion/libsvn_client/mergeinfo.c Thu Oct 10 04:02:02 2013
@@ -1405,17 +1405,21 @@ filter_log_entry_with_rangelist(void *ba
              obviously back.  If it was added or replaced it's still around
              possibly it was replaced one or more times, but it's back now.
              Regardless, LOG_ENTRY->REVISION is *not* an eligible revision! */
-          if (ancestor_is_self /* Explicit mergeinfo on TARGET_PATH_AFFECTED */
+          if (nearest_ancestor_mergeinfo &&
+              ancestor_is_self /* Explicit mergeinfo on TARGET_PATH_AFFECTED */
               && (change->action != 'M'))
             {
               svn_rangelist_t *rangelist =
                   svn_hash_gets(nearest_ancestor_mergeinfo, path);
-              svn_merge_range_t *youngest_range = APR_ARRAY_IDX(
-                rangelist, rangelist->nelts - 1, svn_merge_range_t *);
+              if (rangelist)
+                {
+                  svn_merge_range_t *youngest_range = APR_ARRAY_IDX(
+                    rangelist, rangelist->nelts - 1, svn_merge_range_t *);
 
-              if (youngest_range
-                  && (youngest_range->end > log_entry->revision))
-                continue;
+                  if (youngest_range
+                      && (youngest_range->end > log_entry->revision))
+                    continue;
+                }
             }
 
           if (nearest_ancestor_mergeinfo)



Mime
View raw message