Program: 55033
Project: 55033
Buggy source:
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.layout_novel_info);
  aid=getIntent().getIntExtra("String_Node_Str",1);
  from=getIntent().getStringExtra("String_Node_Str");
  mToolbar=(Toolbar)findViewById(R.id.toolbar_actionbar);
  setSupportActionBar(mToolbar);
  getSupportActionBar().setDisplayHomeAsUpEnabled(true);
  getSupportActionBar().setHomeButtonEnabled(true);
  final Drawable upArrow=getResources().getDrawable(R.drawable.abc_ic_ab_back_mtrl_am_alpha);
  upArrow.setColorFilter(getResources().getColor(R.color.default_white),PorterDuff.Mode.SRC_ATOP);
  getSupportActionBar().setHomeAsUpIndicator(upArrow);
  if (Build.VERSION.SDK_INT >= 16) {
    SystemBarTintManager tintManager=new SystemBarTintManager(this);
    tintManager.setStatusBarTintEnabled(true);
    tintManager.setNavigationBarTintEnabled(true);
    tintManager.setTintAlpha(0.15f);
    tintManager.setTintColor(getResources().getColor(android.R.color.black));
  }
  rlMask=(RelativeLayout)findViewById(R.id.white_mask);
  mLinearLayout=(LinearLayout)findViewById(R.id.novel_info_scroll);
  llCardLayout=(LinearLayout)findViewById(R.id.item_card);
  ivNovelCover=(ImageView)findViewById(R.id.novel_cover);
  tvNovelTitle=(TextView)findViewById(R.id.novel_title);
  tvNovelAuthor=(TextView)findViewById(R.id.novel_author);
  tvNovelStatus=(TextView)findViewById(R.id.novel_status);
  tvNovelUpdate=(TextView)findViewById(R.id.novel_update);
  tvNovelShortIntro=(TableRow)findViewById(R.id.novel_intro_row);
  tvNovelFullIntro=(TextView)findViewById(R.id.novel_intro_full);
  ibNovelOption=(ImageButton)findViewById(R.id.novel_option);
  fabFavorate=(FloatingActionButton)findViewById(R.id.fab_favorate);
  fabDownload=(FloatingActionButton)findViewById(R.id.fab_download);
  famMenu=(FloatingActionsMenu)findViewById(R.id.multiple_actions);
  spb=(SmoothProgressBar)findViewById(R.id.spb);
  ImageLoader.getInstance().displayImage(Wenku8API.getCoverURL(aid),ivNovelCover);
  tvNovelShortIntro.setVisibility(TextView.GONE);
  ibNovelOption.setVisibility(ImageButton.INVISIBLE);
  fabFavorate.setColorFilter(getResources().getColor(R.color.default_white),PorterDuff.Mode.SRC_ATOP);
  fabDownload.setColorFilter(getResources().getColor(R.color.default_white),PorterDuff.Mode.SRC_ATOP);
  llCardLayout.setBackgroundResource(R.color.menu_transparent);
  spb.progressiveStart();
  if (GlobalConfig.testInLocalBookshelf(aid)) {
    fabFavorate.setIcon(R.drawable.ic_favorate_pressed);
  }
  getSupportActionBar().setTitle(R.string.action_novel_info);
  isLoading=true;
  FetchInfoAsyncTask fetchInfoAsyncTask=new FetchInfoAsyncTask();
  fetchInfoAsyncTask.execute(aid);
  famMenu.setOnFloatingActionsMenuUpdateListener(new FloatingActionsMenu.OnFloatingActionsMenuUpdateListener(){
    @Override public void onMenuExpanded(){
      rlMask.setVisibility(View.VISIBLE);
    }
    @Override public void onMenuCollapsed(){
      rlMask.setVisibility(View.INVISIBLE);
    }
  }
);
  rlMask.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (famMenu.isExpanded())       famMenu.collapse();
    }
  }
);
  tvNovelTitle.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (isLoading) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_loading_please_wait),Toast.LENGTH_SHORT).show();
        return;
      }
      new MaterialDialog.Builder(NovelInfoActivity.this).theme(Theme.LIGHT).titleColor(R.color.default_text_color_black).backgroundColorRes(R.color.dlgBackgroundColor).contentColorRes(R.color.dlgContentColor).positiveColorRes(R.color.dlgPositiveButtonColor).title(R.string.dialog_content_novel_title).content(aid + "String_Node_Str" + mNovelItemMeta.title).contentGravity(GravityEnum.CENTER).positiveText(R.string.dialog_positive_known).show();
    }
  }
);
  fabFavorate.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (isLoading) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_loading_please_wait),Toast.LENGTH_SHORT).show();
        return;
      }
      if (GlobalConfig.testInLocalBookshelf(aid)) {
        new MaterialDialog.Builder(NovelInfoActivity.this).callback(new MaterialDialog.ButtonCallback(){
          @Override public void onPositive(          MaterialDialog dialog){
            super.onPositive(dialog);
            for (            VolumeList tempVl : listVolume) {
              for (              ChapterInfo tempCi : tempVl.chapterList) {
                LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + tempCi.cid+ "String_Node_Str");
                LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + tempCi.cid+ "String_Node_Str");
              }
            }
            LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            GlobalConfig.removeFromLocalBookshelf(aid);
            if (!GlobalConfig.testInLocalBookshelf(aid)) {
              Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_removed),Toast.LENGTH_SHORT).show();
              fabFavorate.setIcon(R.drawable.ic_favorate);
            }
 else {
              Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_error),Toast.LENGTH_SHORT).show();
            }
          }
        }
).theme(Theme.LIGHT).backgroundColorRes(R.color.dlgBackgroundColor).contentColorRes(R.color.dlgContentColor).positiveColorRes(R.color.dlgPositiveButtonColor).negativeColorRes(R.color.dlgNegativeButtonColor).content(R.string.dialog_content_sure_to_unfav).contentGravity(GravityEnum.CENTER).positiveText(R.string.dialog_positive_yes).negativeText(R.string.dialog_negative_preferno).show();
      }
 else {
        GlobalConfig.writeFullFileIntoSaveFolder("String_Node_Str",aid + "String_Node_Str",novelFullMeta);
        GlobalConfig.writeFullFileIntoSaveFolder("String_Node_Str",aid + "String_Node_Str",novelFullIntro);
        GlobalConfig.writeFullFileIntoSaveFolder("String_Node_Str",aid + "String_Node_Str",novelFullVolume);
        GlobalConfig.addToLocalBookshelf(aid);
        if (GlobalConfig.testInLocalBookshelf(aid)) {
          Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_added),Toast.LENGTH_SHORT).show();
          fabFavorate.setIcon(R.drawable.ic_favorate_pressed);
        }
 else {
          Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_error),Toast.LENGTH_SHORT).show();
        }
      }
    }
  }
);
  fabDownload.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (isLoading) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_loading_please_wait),Toast.LENGTH_SHORT).show();
        return;
      }
 else       if (!GlobalConfig.testInLocalBookshelf(aid)) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_fav_it_first),Toast.LENGTH_SHORT).show();
        return;
      }
      new MaterialDialog.Builder(NovelInfoActivity.this).callback(new MaterialDialog.ButtonCallback(){
        @Override public void onPositive(        MaterialDialog dialog){
          super.onPositive(dialog);
          isLoading=true;
          final AsyncUpdateCacheTask auct=new AsyncUpdateCacheTask();
          auct.execute(aid);
          pDialog=new MaterialDialog.Builder(NovelInfoActivity.this).theme(Theme.LIGHT).content(R.string.dialog_content_downloading).progress(false,1,true).cancelable(true).cancelListener(new DialogInterface.OnCancelListener(){
            @Override public void onCancel(            DialogInterface dialog){
              isLoading=false;
              auct.cancel(true);
              pDialog.dismiss();
              pDialog=null;
            }
          }
).show();
          pDialog.setProgress(0);
          pDialog.setMaxProgress(1);
          pDialog.show();
        }
      }
).theme(Theme.LIGHT).backgroundColorRes(R.color.dlgBackgroundColor).contentColorRes(R.color.dlgContentColor).positiveColorRes(R.color.dlgPositiveButtonColor).negativeColorRes(R.color.dlgNegativeButtonColor).content(R.string.dialog_content_verify_download).contentGravity(GravityEnum.CENTER).positiveText(R.string.dialog_positive_likethis).negativeText(R.string.dialog_negative_preferno).show();
    }
  }
);
}

Fixed version (ground truth):
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.layout_novel_info);
  aid=getIntent().getIntExtra("String_Node_Str",1);
  from=getIntent().getStringExtra("String_Node_Str");
  mToolbar=(Toolbar)findViewById(R.id.toolbar_actionbar);
  setSupportActionBar(mToolbar);
  getSupportActionBar().setDisplayHomeAsUpEnabled(true);
  getSupportActionBar().setHomeButtonEnabled(true);
  final Drawable upArrow=getResources().getDrawable(R.drawable.abc_ic_ab_back_mtrl_am_alpha);
  upArrow.setColorFilter(getResources().getColor(R.color.default_white),PorterDuff.Mode.SRC_ATOP);
  getSupportActionBar().setHomeAsUpIndicator(upArrow);
  if (Build.VERSION.SDK_INT >= 16) {
    SystemBarTintManager tintManager=new SystemBarTintManager(this);
    tintManager.setStatusBarTintEnabled(true);
    tintManager.setNavigationBarTintEnabled(true);
    tintManager.setTintAlpha(0.15f);
    tintManager.setTintColor(getResources().getColor(android.R.color.black));
  }
  if (ImageLoader.getInstance() == null || !ImageLoader.getInstance().isInited()) {
    GlobalConfig.initImageLoader(this);
  }
  rlMask=(RelativeLayout)findViewById(R.id.white_mask);
  mLinearLayout=(LinearLayout)findViewById(R.id.novel_info_scroll);
  llCardLayout=(LinearLayout)findViewById(R.id.item_card);
  ivNovelCover=(ImageView)findViewById(R.id.novel_cover);
  tvNovelTitle=(TextView)findViewById(R.id.novel_title);
  tvNovelAuthor=(TextView)findViewById(R.id.novel_author);
  tvNovelStatus=(TextView)findViewById(R.id.novel_status);
  tvNovelUpdate=(TextView)findViewById(R.id.novel_update);
  tvNovelShortIntro=(TableRow)findViewById(R.id.novel_intro_row);
  tvNovelFullIntro=(TextView)findViewById(R.id.novel_intro_full);
  ibNovelOption=(ImageButton)findViewById(R.id.novel_option);
  fabFavorate=(FloatingActionButton)findViewById(R.id.fab_favorate);
  fabDownload=(FloatingActionButton)findViewById(R.id.fab_download);
  famMenu=(FloatingActionsMenu)findViewById(R.id.multiple_actions);
  spb=(SmoothProgressBar)findViewById(R.id.spb);
  ImageLoader.getInstance().displayImage(Wenku8API.getCoverURL(aid),ivNovelCover);
  tvNovelShortIntro.setVisibility(TextView.GONE);
  ibNovelOption.setVisibility(ImageButton.INVISIBLE);
  fabFavorate.setColorFilter(getResources().getColor(R.color.default_white),PorterDuff.Mode.SRC_ATOP);
  fabDownload.setColorFilter(getResources().getColor(R.color.default_white),PorterDuff.Mode.SRC_ATOP);
  llCardLayout.setBackgroundResource(R.color.menu_transparent);
  spb.progressiveStart();
  if (GlobalConfig.testInLocalBookshelf(aid)) {
    fabFavorate.setIcon(R.drawable.ic_favorate_pressed);
  }
  getSupportActionBar().setTitle(R.string.action_novel_info);
  isLoading=true;
  FetchInfoAsyncTask fetchInfoAsyncTask=new FetchInfoAsyncTask();
  fetchInfoAsyncTask.execute(aid);
  famMenu.setOnFloatingActionsMenuUpdateListener(new FloatingActionsMenu.OnFloatingActionsMenuUpdateListener(){
    @Override public void onMenuExpanded(){
      rlMask.setVisibility(View.VISIBLE);
    }
    @Override public void onMenuCollapsed(){
      rlMask.setVisibility(View.INVISIBLE);
    }
  }
);
  rlMask.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (famMenu.isExpanded())       famMenu.collapse();
    }
  }
);
  tvNovelTitle.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (isLoading) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_loading_please_wait),Toast.LENGTH_SHORT).show();
        return;
      }
      new MaterialDialog.Builder(NovelInfoActivity.this).theme(Theme.LIGHT).titleColor(R.color.dlgTitleColor).backgroundColorRes(R.color.dlgBackgroundColor).contentColorRes(R.color.dlgContentColor).positiveColorRes(R.color.dlgPositiveButtonColor).title(R.string.dialog_content_novel_title).content(aid + "String_Node_Str" + mNovelItemMeta.title).contentGravity(GravityEnum.CENTER).positiveText(R.string.dialog_positive_known).show();
    }
  }
);
  fabFavorate.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (isLoading) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_loading_please_wait),Toast.LENGTH_SHORT).show();
        return;
      }
      if (GlobalConfig.testInLocalBookshelf(aid)) {
        new MaterialDialog.Builder(NovelInfoActivity.this).callback(new MaterialDialog.ButtonCallback(){
          @Override public void onPositive(          MaterialDialog dialog){
            super.onPositive(dialog);
            for (            VolumeList tempVl : listVolume) {
              for (              ChapterInfo tempCi : tempVl.chapterList) {
                LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + tempCi.cid+ "String_Node_Str");
                LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + tempCi.cid+ "String_Node_Str");
              }
            }
            LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getFirstFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            LightCache.deleteFile(GlobalConfig.getSecondFullSaveFilePath(),"String_Node_Str" + File.separator + aid+ "String_Node_Str");
            GlobalConfig.removeFromLocalBookshelf(aid);
            if (!GlobalConfig.testInLocalBookshelf(aid)) {
              Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_removed),Toast.LENGTH_SHORT).show();
              fabFavorate.setIcon(R.drawable.ic_favorate);
            }
 else {
              Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_error),Toast.LENGTH_SHORT).show();
            }
          }
        }
).theme(Theme.LIGHT).backgroundColorRes(R.color.dlgBackgroundColor).contentColorRes(R.color.dlgContentColor).positiveColorRes(R.color.dlgPositiveButtonColor).negativeColorRes(R.color.dlgNegativeButtonColor).content(R.string.dialog_content_sure_to_unfav).contentGravity(GravityEnum.CENTER).positiveText(R.string.dialog_positive_yes).negativeText(R.string.dialog_negative_preferno).show();
      }
 else {
        GlobalConfig.writeFullFileIntoSaveFolder("String_Node_Str",aid + "String_Node_Str",novelFullMeta);
        GlobalConfig.writeFullFileIntoSaveFolder("String_Node_Str",aid + "String_Node_Str",novelFullIntro);
        GlobalConfig.writeFullFileIntoSaveFolder("String_Node_Str",aid + "String_Node_Str",novelFullVolume);
        GlobalConfig.addToLocalBookshelf(aid);
        if (GlobalConfig.testInLocalBookshelf(aid)) {
          Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_added),Toast.LENGTH_SHORT).show();
          fabFavorate.setIcon(R.drawable.ic_favorate_pressed);
        }
 else {
          Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.bookshelf_error),Toast.LENGTH_SHORT).show();
        }
      }
    }
  }
);
  fabDownload.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      if (isLoading) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_loading_please_wait),Toast.LENGTH_SHORT).show();
        return;
      }
 else       if (!GlobalConfig.testInLocalBookshelf(aid)) {
        Toast.makeText(NovelInfoActivity.this,getResources().getString(R.string.system_fav_it_first),Toast.LENGTH_SHORT).show();
        return;
      }
      new MaterialDialog.Builder(NovelInfoActivity.this).theme(Theme.LIGHT).title(R.string.dialog_title_choose_download_option).backgroundColorRes(R.color.dlgBackgroundColor).titleColor(R.color.dlgTitleColor).negativeText(R.string.dialog_negative_pass).negativeColorRes(R.color.dlgNegativeButtonColor).itemsGravity(GravityEnum.CENTER).items(R.array.download_option).itemsCallback(new MaterialDialog.ListCallback(){
        @Override public void onSelection(        MaterialDialog dialog,        View view,        int which,        CharSequence text){
switch (which) {
case 0:
            break;
case 1:
          new MaterialDialog.Builder(NovelInfoActivity.this).callback(new MaterialDialog.ButtonCallback(){
            @Override public void onPositive(            MaterialDialog dialog){
              super.onPositive(dialog);
              isLoading=true;
              final AsyncUpdateCacheTask auct=new AsyncUpdateCacheTask();
              auct.execute(aid);
              pDialog=new MaterialDialog.Builder(NovelInfoActivity.this).theme(Theme.LIGHT).content(R.string.dialog_content_downloading).progress(false,1,true).cancelable(true).cancelListener(new DialogInterface.OnCancelListener(){
                @Override public void onCancel(                DialogInterface dialog){
                  isLoading=false;
                  auct.cancel(true);
                  pDialog.dismiss();
                  pDialog=null;
                }
              }
).show();
              pDialog.setProgress(0);
              pDialog.setMaxProgress(1);
              pDialog.show();
            }
          }
).theme(Theme.LIGHT).backgroundColorRes(R.color.dlgBackgroundColor).contentColorRes(R.color.dlgContentColor).positiveColorRes(R.color.dlgPositiveButtonColor).negativeColorRes(R.color.dlgNegativeButtonColor).content(R.string.dialog_content_verify_download).contentGravity(GravityEnum.CENTER).positiveText(R.string.dialog_positive_likethis).negativeText(R.string.dialog_negative_preferno).show();
        break;
case 2:
      break;
case 3:
    break;
}
}
}
).show();
}
}
);
}