Program: 70893
Project: 70893
Buggy source:
private GL3Object buildPointGLO(GL3 gl,int pidx,int nidx,int cidx,int tidx,int oidx){
  int nattribs=0;
  if (pidx >= 0) {
    nattribs++;
  }
  if (nidx >= 0) {
    nattribs++;
  }
  if (cidx >= 0) {
    nattribs++;
  }
  if (tidx >= 0) {
    tidx++;
  }
  GL3VertexAttributeArray[] attribs=new GL3VertexAttributeArray[nattribs];
  int aidx=0;
  if (pidx >= 0) {
    AttributeInfo pinfo=positionInfo[pidx];
    BufferObject vbo=vbos[pinfo.vboIndex];
    BufferStorage bs=positionPutter.storage();
    int offset=pinfo.offset + pointGroupOffsets[oidx] * pinfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_POSITION,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,pinfo.stride,pinfo.count);
    aidx++;
  }
  if (nidx >= 0) {
    AttributeInfo ninfo=normalInfo[nidx];
    BufferObject vbo=vbos[ninfo.vboIndex];
    BufferStorage bs=normalPutter.storage();
    int offset=ninfo.offset + pointGroupOffsets[oidx] * ninfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_NORMAL,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,ninfo.stride,ninfo.count);
    aidx++;
  }
  if (cidx >= 0) {
    AttributeInfo cinfo=colorInfo[cidx];
    BufferObject vbo=vbos[cinfo.vboIndex];
    BufferStorage bs=colorPutter.storage();
    int offset=cinfo.offset + pointGroupOffsets[oidx] * cinfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_COLOR,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,cinfo.stride,cinfo.count);
    aidx++;
  }
  if (tidx >= 0) {
    AttributeInfo tinfo=textureInfo[tidx];
    BufferObject vbo=vbos[tinfo.vboIndex];
    BufferStorage bs=texturePutter.storage();
    int offset=tinfo.offset + pointGroupOffsets[oidx] * tinfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_TEXTURE,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,tinfo.stride,tinfo.count);
    aidx++;
  }
  GL3Object glo=new GL3Object(gl,attribs,null,GL.GL_POINTS);
  return glo;
}

Fixed version (ground truth):
private GL3Object buildPointGLO(GL3 gl,int pidx,int nidx,int cidx,int tidx,int oidx){
  int nattribs=0;
  if (pidx >= 0) {
    nattribs++;
  }
  if (nidx >= 0) {
    nattribs++;
  }
  if (cidx >= 0) {
    nattribs++;
  }
  if (tidx >= 0) {
    tidx++;
  }
  GL3VertexAttributeArray[] attribs=new GL3VertexAttributeArray[nattribs];
  int pointCount=pointGroupOffsets[oidx + 1] - pointGroupOffsets[oidx];
  int aidx=0;
  if (pidx >= 0) {
    AttributeInfo pinfo=positionInfo[pidx];
    BufferObject vbo=vbos[pinfo.vboIndex];
    BufferStorage bs=positionPutter.storage();
    int offset=pinfo.offset + pointGroupOffsets[oidx] * pinfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_POSITION,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,pinfo.stride,pointCount);
    aidx++;
  }
  if (nidx >= 0) {
    AttributeInfo ninfo=normalInfo[nidx];
    BufferObject vbo=vbos[ninfo.vboIndex];
    BufferStorage bs=normalPutter.storage();
    int offset=ninfo.offset + pointGroupOffsets[oidx] * ninfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_NORMAL,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,ninfo.stride,pointCount);
    aidx++;
  }
  if (cidx >= 0) {
    AttributeInfo cinfo=colorInfo[cidx];
    BufferObject vbo=vbos[cinfo.vboIndex];
    BufferStorage bs=colorPutter.storage();
    int offset=cinfo.offset + pointGroupOffsets[oidx] * cinfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_COLOR,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,cinfo.stride,pointCount);
    aidx++;
  }
  if (tidx >= 0) {
    AttributeInfo tinfo=textureInfo[tidx];
    BufferObject vbo=vbos[tinfo.vboIndex];
    BufferStorage bs=texturePutter.storage();
    int offset=tinfo.offset + pointGroupOffsets[oidx] * tinfo.stride;
    attribs[aidx]=new GL3VertexAttributeArray(vbo,GL3VertexAttribute.VERTEX_TEXTURE,GL3Util.getGLType(bs.type()),bs.size(),bs.isNormalized(),offset,tinfo.stride,pointCount);
    aidx++;
  }
  GL3Object glo=new GL3Object(gl,attribs,null,GL.GL_POINTS);
  return glo;
}