Program: 35568
Project: 35568
Buggy source:
@OnClick(R.id.call_control_microphone) public void onMicrophoneClick(){
  if (getActivity() != null && EffortlessPermissions.hasPermissions(getActivity(),PERMISSIONS_MICROPHONE)) {
    if (getActivity() != null && !appPreferences.getPushToTalkIntroShown()) {
      spotlightView=new SpotlightView.Builder(getActivity()).introAnimationDuration(300).enableRevealAnimation(true).performClick(false).fadeinTextDuration(400).headingTvColor(getResources().getColor(R.color.colorPrimary)).headingTvSize(20).headingTvText(getResources().getString(R.string.nc_push_to_talk)).subHeadingTvColor(getResources().getColor(R.color.white)).subHeadingTvSize(16).subHeadingTvText(getResources().getString(R.string.nc_push_to_talk_desc)).maskColor(Color.parseColor("String_Node_Str")).target(microphoneControlButton).lineAnimDuration(400).lineAndArcColor(getResources().getColor(R.color.colorPrimary)).enableDismissAfterShown(true).dismissOnBackPress(true).usageId("String_Node_Str").show();
      appPreferences.setPushToTalkIntroShown(true);
    }
    if (!isPTTActive) {
      audioOn=!audioOn;
      if (audioOn) {
        microphoneControlButton.getFrontImageView().setImageResource(R.drawable.ic_mic_white_24px);
      }
 else {
        microphoneControlButton.getFrontImageView().setImageResource(R.drawable.ic_mic_off_white_24px);
      }
      toggleMedia(audioOn,false);
    }
 else {
      microphoneControlButton.getFrontImageView().setImageResource(R.drawable.ic_mic_white_24px);
      pulseAnimation.start();
      toggleMedia(true,false);
    }
    if (isVoiceOnlyCall && !inCall) {
      startCall();
    }
  }
 else   if (getActivity() != null && EffortlessPermissions.somePermissionPermanentlyDenied(getActivity(),PERMISSIONS_MICROPHONE)) {
    OpenAppDetailsDialogFragment.show(R.string.nc_microphone_permission_permanently_denied,R.string.nc_permissions_settings,(AppCompatActivity)getActivity());
  }
 else {
    if (getActivity() != null) {
      EffortlessPermissions.requestPermissions(getActivity(),R.string.nc_permissions_audio,R.string.nc_proceed,R.string.nc_empty,100,PERMISSIONS_MICROPHONE);
    }
  }
}

Fixed version (ground truth):
@OnClick(R.id.call_control_microphone) public void onMicrophoneClick(){
  if (getActivity() != null && EffortlessPermissions.hasPermissions(getActivity(),PERMISSIONS_MICROPHONE)) {
    if (getActivity() != null && !appPreferences.getPushToTalkIntroShown()) {
      spotlightView=new SpotlightView.Builder(getActivity()).introAnimationDuration(300).enableRevealAnimation(true).performClick(false).fadeinTextDuration(400).headingTvColor(getResources().getColor(R.color.colorPrimary)).headingTvSize(20).headingTvText(getResources().getString(R.string.nc_push_to_talk)).subHeadingTvColor(getResources().getColor(R.color.white)).subHeadingTvSize(16).subHeadingTvText(getResources().getString(R.string.nc_push_to_talk_desc)).maskColor(Color.parseColor("String_Node_Str")).target(microphoneControlButton).lineAnimDuration(400).lineAndArcColor(getResources().getColor(R.color.colorPrimary)).enableDismissAfterShown(true).dismissOnBackPress(true).usageId("String_Node_Str").show();
      appPreferences.setPushToTalkIntroShown(true);
    }
    if (!isPTTActive) {
      audioOn=!audioOn;
      if (audioOn) {
        microphoneControlButton.getFrontImageView().setImageResource(R.drawable.ic_mic_white_24px);
      }
 else {
        microphoneControlButton.getFrontImageView().setImageResource(R.drawable.ic_mic_off_white_24px);
      }
      toggleMedia(audioOn,false);
    }
 else {
      microphoneControlButton.getFrontImageView().setImageResource(R.drawable.ic_mic_white_24px);
      pulseAnimation.start();
      toggleMedia(true,false);
    }
    if (isVoiceOnlyCall && !inCall) {
      startCall();
    }
  }
 else   if (getActivity() != null && EffortlessPermissions.somePermissionPermanentlyDenied(getActivity(),PERMISSIONS_MICROPHONE)) {
    OpenAppDetailsDialogFragment.show(R.string.nc_microphone_permission_permanently_denied,R.string.nc_permissions_settings,(AppCompatActivity)getActivity());
  }
 else {
    requestPermissions(PERMISSIONS_MICROPHONE,100);
  }
}