Program: 193875
Project: 193875
Buggy source:
/** 
 * Dispatch creation of   {@link ViewStructure} down the hierarchy.  This implementationadds in all child views of the view group, in addition to calling the default View implementation.
 */
public void dispatchProvideStructure(ViewStructure structure){
  super.dispatchProvideStructure(structure);
  if (!isAssistBlocked()) {
    if (structure.getChildCount() == 0) {
      final int childrenCount=getChildCount();
      if (childrenCount > 0) {
        structure.setChildCount(childrenCount);
        final ArrayList<View> preorderedList=buildOrderedChildList();
        final boolean customOrder=preorderedList == null && isChildrenDrawingOrderEnabled();
        final View[] children=mChildren;
        for (int i=0; i < childrenCount; i++) {
          final int childIndex=customOrder ? getChildDrawingOrder(childrenCount,i) : i;
          final View child=(preorderedList == null) ? children[childIndex] : preorderedList.get(childIndex);
          ViewStructure cstructure=structure.newChild(i);
          child.dispatchProvideStructure(cstructure);
        }
      }
    }
  }
}

Fixed version (ground truth):
/** 
 * Dispatch creation of   {@link ViewStructure} down the hierarchy.  This implementationadds in all child views of the view group, in addition to calling the default View implementation.
 */
public void dispatchProvideStructure(ViewStructure structure){
  super.dispatchProvideStructure(structure);
  if (!isAssistBlocked()) {
    if (structure.getChildCount() == 0) {
      final int childrenCount=getChildCount();
      if (childrenCount > 0) {
        structure.setChildCount(childrenCount);
        ArrayList<View> preorderedList=buildOrderedChildList();
        boolean customOrder=preorderedList == null && isChildrenDrawingOrderEnabled();
        final View[] children=mChildren;
        for (int i=0; i < childrenCount; i++) {
          int childIndex;
          try {
            childIndex=customOrder ? getChildDrawingOrder(childrenCount,i) : i;
          }
 catch (          IndexOutOfBoundsException e) {
            childIndex=i;
            if (mContext.getApplicationInfo().targetSdkVersion < Build.VERSION_CODES.M) {
              Log.w(TAG,"String_Node_Str" + i + "String_Node_Str"+ childrenCount,e);
              customOrder=false;
              if (i > 0) {
                int[] permutation=new int[childrenCount];
                SparseBooleanArray usedIndices=new SparseBooleanArray();
                for (int j=0; j < i; j++) {
                  permutation[j]=getChildDrawingOrder(childrenCount,j);
                  usedIndices.put(permutation[j],true);
                }
                int nextIndex=0;
                for (int j=i; j < childrenCount; j++) {
                  while (usedIndices.get(nextIndex,false)) {
                    nextIndex++;
                  }
                  permutation[j]=nextIndex;
                  nextIndex++;
                }
                preorderedList=new ArrayList<>(childrenCount);
                for (int j=0; j < childrenCount; j++) {
                  preorderedList.add(children[permutation[j]]);
                }
              }
            }
 else {
              throw e;
            }
          }
          final View child=(preorderedList == null) ? children[childIndex] : preorderedList.get(childIndex);
          ViewStructure cstructure=structure.newChild(i);
          child.dispatchProvideStructure(cstructure);
        }
      }
    }
  }
}