Commit cf61f514 authored by unknown's avatar unknown
Browse files

bug#13610 - ndb

  incorrectly computed m_gcp_complete_rep for partial start
  gives assert in debug mode, and error in ndbapi in release


storage/ndb/src/kernel/blocks/suma/Suma.cpp:
  Compute no of gcp_complete_rep that Im contributioning correctly
    by computing distinct nodes of all the buckets im handling as if all were started
parent 282855e9
Loading
Loading
Loading
Loading
+12 −1
Original line number Diff line number Diff line
@@ -198,7 +198,18 @@ Suma::execSTTOR(Signal* signal) {
    }
    
    if(!m_active_buckets.isclear())
      m_gcp_complete_rep_count = 1; // I contribute 1 gcp complete rep
    {
      NdbNodeBitmask tmp;
      Uint32 bucket = 0;
      while (m_active_buckets.find(bucket) != Bucket_mask::NotFound)
      {
	tmp.set(get_responsible_node(bucket, c_nodes_in_nodegroup_mask));
	bucket++;
      }
      
      ndbassert(tmp.get(getOwnNodeId()));
      m_gcp_complete_rep_count = tmp.count();// I contribute 1 gcp complete rep
    }
    else
      m_gcp_complete_rep_count = 0; // I contribute 1 gcp complete rep