Program: 164517
Project: 164517
Buggy source:
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.activity_view);
  mSideGalleryFragment=(SideGalleryFragment)getFragmentManager().findFragmentById(R.id.sideGallery);
  mMultiView.setErrorButtonText(R.id.errorButton,R.string.load_comments);
  findViewById(R.id.topContainer).setBackgroundColor(getResources().getColor(theme.primaryColor));
  mCommentListHeader=(TextViewRoboto)View.inflate(getApplicationContext(),R.layout.previous_comments_header,null);
  Drawable[] drawables=mCommentListHeader.getCompoundDrawables();
  if (drawables != null && drawables.length > 0 && drawables[0] instanceof LayerDrawable) {
    GradientDrawable drawable=(GradientDrawable)((LayerDrawable)drawables[0]).getDrawable(0);
    drawable.setColor(getResources().getColor(theme.accentColor));
  }
  mCommentList.addHeaderView(mCommentListHeader);
  mCommentList.removeHeaderView(mCommentListHeader);
  mViewPager.setPageTransformer(true,new ZoomOutPageTransformer());
  mViewPager.setOnPageChangeListener(new ViewPager.OnPageChangeListener(){
    @Override public void onPageScrolled(    int position,    float positionOffset,    int positionOffsetPixels){
    }
    @Override public void onPageSelected(    int position){
      if (!mIsResuming) {
        mCurrentPosition=position;
        loadComments();
        invalidateOptionsMenu();
        if (mSideGalleryFragment != null) {
          mSideGalleryFragment.onPositionChanged(position);
        }
      }
      mIsResuming=false;
    }
    @Override public void onPageScrollStateChanged(    int state){
    }
  }
);
  mCommentList.setOnItemClickListener(new AdapterView.OnItemClickListener(){
    @Override public void onItemClick(    AdapterView<?> adapterView,    View view,    int position,    long l){
      onListItemClick(position - mCommentList.getHeaderViewsCount());
    }
  }
);
  initSlidingView();
  handleIntent(getIntent(),savedInstanceState);
}

Fixed version (ground truth):
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.activity_view);
  mSideGalleryFragment=(SideGalleryFragment)getFragmentManager().findFragmentById(R.id.sideGallery);
  mMultiView.setErrorButtonText(R.id.errorButton,R.string.load_comments);
  findViewById(R.id.topContainer).setBackgroundColor(getResources().getColor(theme.primaryColor));
  mCommentListHeader=(TextViewRoboto)View.inflate(getApplicationContext(),R.layout.previous_comments_header,null);
  Drawable[] drawables=mCommentListHeader.getCompoundDrawables();
  if (drawables != null && drawables.length > 0 && drawables[0] instanceof LayerDrawable) {
    GradientDrawable drawable=(GradientDrawable)((LayerDrawable)drawables[0]).getDrawable(0);
    drawable.setColor(getResources().getColor(theme.accentColor));
  }
  mCommentList.addHeaderView(mCommentListHeader);
  mViewPager.setPageTransformer(true,new ZoomOutPageTransformer());
  mViewPager.setOnPageChangeListener(new ViewPager.OnPageChangeListener(){
    @Override public void onPageScrolled(    int position,    float positionOffset,    int positionOffsetPixels){
    }
    @Override public void onPageSelected(    int position){
      if (!mIsResuming) {
        mCurrentPosition=position;
        loadComments();
        invalidateOptionsMenu();
        if (mSideGalleryFragment != null) {
          mSideGalleryFragment.onPositionChanged(position);
        }
      }
      mIsResuming=false;
    }
    @Override public void onPageScrollStateChanged(    int state){
    }
  }
);
  mCommentList.setOnItemClickListener(new AdapterView.OnItemClickListener(){
    @Override public void onItemClick(    AdapterView<?> adapterView,    View view,    int position,    long l){
      onListItemClick(position - mCommentList.getHeaderViewsCount());
    }
  }
);
  initSlidingView();
  handleIntent(getIntent(),savedInstanceState);
}