Program: 26149
Project: 26149
Buggy source:
@Override protected void onCreate(Bundle savedInstanceState){
  ThemeChooser.chooseTheme(this);
  super.onCreate(savedInstanceState);
  setContentView(R.layout.activity_news_detail);
  ButterKnife.inject(this);
  if (toolbar != null) {
    setSupportActionBar(toolbar);
  }
  pDelayHandler=new PostDelayHandler(this);
  _Reader=new OwnCloud_Reader();
  dbConn=new DatabaseConnectionOrm(this);
  Intent intent=getIntent();
  int item_id=0;
  if (intent.hasExtra(NewsReaderListActivity.ITEM_ID))   item_id=intent.getExtras().getInt(NewsReaderListActivity.ITEM_ID);
  if (intent.hasExtra(NewsReaderListActivity.TITEL))   getSupportActionBar().setTitle(intent.getExtras().getString(NewsReaderListActivity.TITEL));
  getSupportActionBar().setDisplayHomeAsUpEnabled(true);
  rssItems=dbConn.getCurrentRssItemView(getSortDirectionFromSettings(this));
  if (intent.hasExtra(WidgetProvider.RSS_ITEM_ID)) {
    long rss_item_id=intent.getExtras().getLong(WidgetProvider.RSS_ITEM_ID);
    for (    RssItem rssItem : rssItems) {
      if (rss_item_id == rssItem.getId()) {
        getSupportActionBar().setTitle(rssItem.getTitle());
        break;
      }
 else       item_id++;
    }
  }
  mSectionsPagerAdapter=new SectionsPagerAdapter(getSupportFragmentManager());
  mViewPager=(ViewPager)findViewById(R.id.pager);
  mViewPager.setAdapter(mSectionsPagerAdapter);
  try {
    mViewPager.setCurrentItem(item_id,true);
    PageChanged(item_id);
  }
 catch (  Exception ex) {
    ex.printStackTrace();
  }
  mViewPager.addOnPageChangeListener(onPageChangeListener);
  mCustomTabsSupported=bindCustomTabsService();
}

Fixed version (ground truth):
@Override protected void onCreate(Bundle savedInstanceState){
  ThemeChooser.chooseTheme(this);
  super.onCreate(savedInstanceState);
  setContentView(R.layout.activity_news_detail);
  ButterKnife.inject(this);
  if (toolbar != null) {
    setSupportActionBar(toolbar);
  }
  pDelayHandler=new PostDelayHandler(this);
  dbConn=new DatabaseConnectionOrm(this);
  Intent intent=getIntent();
  int item_id=0;
  if (intent.hasExtra(NewsReaderListActivity.ITEM_ID))   item_id=intent.getExtras().getInt(NewsReaderListActivity.ITEM_ID);
  if (intent.hasExtra(NewsReaderListActivity.TITEL))   getSupportActionBar().setTitle(intent.getExtras().getString(NewsReaderListActivity.TITEL));
  getSupportActionBar().setDisplayHomeAsUpEnabled(true);
  rssItems=dbConn.getCurrentRssItemView(getSortDirectionFromSettings(this));
  if (intent.hasExtra(WidgetProvider.RSS_ITEM_ID)) {
    long rss_item_id=intent.getExtras().getLong(WidgetProvider.RSS_ITEM_ID);
    for (    RssItem rssItem : rssItems) {
      if (rss_item_id == rssItem.getId()) {
        getSupportActionBar().setTitle(rssItem.getTitle());
        break;
      }
 else       item_id++;
    }
  }
  mSectionsPagerAdapter=new SectionsPagerAdapter(getSupportFragmentManager());
  mViewPager=(ViewPager)findViewById(R.id.pager);
  mViewPager.setAdapter(mSectionsPagerAdapter);
  try {
    mViewPager.setCurrentItem(item_id,true);
    PageChanged(item_id);
  }
 catch (  Exception ex) {
    ex.printStackTrace();
  }
  mViewPager.addOnPageChangeListener(onPageChangeListener);
  mCustomTabsSupported=bindCustomTabsService();
}