Program: 80555
Project: 80555
Buggy source:
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  mInstance=this;
  setContentView(R.layout.activity_settings);
  prefs=new PrefsGet(getSharedPreferences(getPackageName(),Context.MODE_MULTI_PROCESS));
  mContext=this;
  if (showChangelog(prefs)) {
    launchChangelog();
  }
  display=getWindowManager().getDefaultDisplay();
  updateDisplayWidth();
  myService=new ServiceCall(mContext);
  myService.setConnection(mConnection);
  final ActionBar actionBar=getActionBar();
  actionBar.setTitle(R.string.title_activity_settings);
  actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_TABS);
  actionBar.setCustomView(R.layout.action_spinner);
  setUpSpinner((Spinner)actionBar.getCustomView().findViewById(R.id.config_spinner));
  actionBar.setDisplayShowCustomEnabled(true);
  mSectionsPagerAdapter=new SectionsPagerAdapter(getFragmentManager());
  mViewPager=(ViewPager)findViewById(R.id.pager);
  mViewPager.setAdapter(mSectionsPagerAdapter);
  mViewPager.setOffscreenPageLimit(4);
  mGetFragments=new GetFragments();
  mGetFragments.setFm(getFragmentManager());
  mGetFragments.setVp(mViewPager);
  ViewPager.OnPageChangeListener pageChangeListener=new ViewPager.SimpleOnPageChangeListener(){
    @Override public void onPageSelected(    int position){
      actionBar.setSelectedNavigationItem(position);
    }
  }
;
  mViewPager.setOnPageChangeListener(pageChangeListener);
  for (int i=0; i < mSectionsPagerAdapter.getCount(); i++) {
    actionBar.addTab(actionBar.newTab().setText(mSectionsPagerAdapter.getPageTitle(i)).setTabListener(this));
  }
  db=TasksDataSource.getInstance(this);
  db.open();
  int allTasksSize=db.getAllTasks().size();
  db.close();
  if (allTasksSize == 0) {
    newStart=true;
  }
  pageChangeListener.onPageSelected(GENERAL_TAB);
}

Fixed version (ground truth):
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  mInstance=this;
  setContentView(R.layout.activity_settings);
  prefs=new PrefsGet(getSharedPreferences(getPackageName(),Context.MODE_MULTI_PROCESS));
  mContext=this;
  if (showChangelog(prefs)) {
    launchChangelog();
  }
  display=getWindowManager().getDefaultDisplay();
  updateDisplayWidth();
  myService=new ServiceCall(mContext);
  myService.setConnection(mConnection);
  final ActionBar actionBar=getActionBar();
  actionBar.setTitle(R.string.title_activity_settings);
  actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_TABS);
  actionBar.setCustomView(R.layout.action_spinner);
  setUpSpinner((Spinner)actionBar.getCustomView().findViewById(R.id.config_spinner));
  actionBar.setDisplayShowCustomEnabled(true);
  mSectionsPagerAdapter=new SectionsPagerAdapter(getFragmentManager());
  mViewPager=(ViewPager)findViewById(R.id.pager);
  mViewPager.setAdapter(mSectionsPagerAdapter);
  mViewPager.setOffscreenPageLimit(4);
  mGetFragments=new GetFragments();
  mGetFragments.setFm(getFragmentManager());
  mGetFragments.setVp(mViewPager);
  ViewPager.OnPageChangeListener pageChangeListener=new ViewPager.SimpleOnPageChangeListener(){
    @Override public void onPageSelected(    int position){
      actionBar.setSelectedNavigationItem(position);
    }
  }
;
  mViewPager.setOnPageChangeListener(pageChangeListener);
  for (int i=0; i < mSectionsPagerAdapter.getCount(); i++) {
    actionBar.addTab(actionBar.newTab().setText(mSectionsPagerAdapter.getPageTitle(i)).setTabListener(this));
  }
  pageChangeListener.onPageSelected(GENERAL_TAB);
}