Program: 192983
Project: 192983
Buggy source:
private void relaunchActivityLocked(ActivityRecord r,int changes,boolean andResume,boolean preserveWindow){
  if (mService.mSuppressResizeConfigChanges && preserveWindow) {
    return;
  }
  List<ResultInfo> results=null;
  List<ReferrerIntent> newIntents=null;
  if (andResume) {
    results=r.results;
    newIntents=r.newIntents;
  }
  if (DEBUG_SWITCH)   Slog.v(TAG_SWITCH,"String_Node_Str" + r + "String_Node_Str"+ results+ "String_Node_Str"+ newIntents+ "String_Node_Str"+ andResume+ "String_Node_Str"+ preserveWindow);
  EventLog.writeEvent(andResume ? EventLogTags.AM_RELAUNCH_RESUME_ACTIVITY : EventLogTags.AM_RELAUNCH_ACTIVITY,r.userId,System.identityHashCode(r),r.task.taskId,r.shortComponentName);
  r.startFreezingScreenLocked(r.app,0);
  mStackSupervisor.removeChildActivityContainers(r);
  try {
    if (DEBUG_SWITCH || DEBUG_STATES)     Slog.i(TAG_SWITCH,"String_Node_Str" + (andResume ? "String_Node_Str" : "String_Node_Str") + "String_Node_Str"+ r);
    r.forceNewConfig=false;
    r.app.thread.scheduleRelaunchActivity(r.appToken,results,newIntents,changes,!andResume,new Configuration(mService.mConfiguration),new Configuration(r.task.mOverrideConfig),preserveWindow);
    mStackSupervisor.activityRelaunchingLocked(r);
  }
 catch (  RemoteException e) {
    if (DEBUG_SWITCH || DEBUG_STATES)     Slog.i(TAG_SWITCH,"String_Node_Str",e);
  }
  if (andResume) {
    r.results=null;
    r.newIntents=null;
    r.state=ActivityState.RESUMED;
  }
 else {
    mHandler.removeMessages(PAUSE_TIMEOUT_MSG,r);
    r.state=ActivityState.PAUSED;
  }
}

Fixed version (ground truth):
private void relaunchActivityLocked(ActivityRecord r,int changes,boolean andResume,boolean preserveWindow){
  if (mService.mSuppressResizeConfigChanges && preserveWindow) {
    r.configChangeFlags=0;
    return;
  }
  List<ResultInfo> results=null;
  List<ReferrerIntent> newIntents=null;
  if (andResume) {
    results=r.results;
    newIntents=r.newIntents;
  }
  if (DEBUG_SWITCH)   Slog.v(TAG_SWITCH,"String_Node_Str" + r + "String_Node_Str"+ results+ "String_Node_Str"+ newIntents+ "String_Node_Str"+ andResume+ "String_Node_Str"+ preserveWindow);
  EventLog.writeEvent(andResume ? EventLogTags.AM_RELAUNCH_RESUME_ACTIVITY : EventLogTags.AM_RELAUNCH_ACTIVITY,r.userId,System.identityHashCode(r),r.task.taskId,r.shortComponentName);
  r.startFreezingScreenLocked(r.app,0);
  mStackSupervisor.removeChildActivityContainers(r);
  try {
    if (DEBUG_SWITCH || DEBUG_STATES)     Slog.i(TAG_SWITCH,"String_Node_Str" + (andResume ? "String_Node_Str" : "String_Node_Str") + "String_Node_Str"+ r);
    r.forceNewConfig=false;
    r.app.thread.scheduleRelaunchActivity(r.appToken,results,newIntents,changes,!andResume,new Configuration(mService.mConfiguration),new Configuration(r.task.mOverrideConfig),preserveWindow);
    mStackSupervisor.activityRelaunchingLocked(r);
  }
 catch (  RemoteException e) {
    if (DEBUG_SWITCH || DEBUG_STATES)     Slog.i(TAG_SWITCH,"String_Node_Str",e);
  }
  if (andResume) {
    r.results=null;
    r.newIntents=null;
    r.state=ActivityState.RESUMED;
  }
 else {
    mHandler.removeMessages(PAUSE_TIMEOUT_MSG,r);
    r.state=ActivityState.PAUSED;
  }
  r.configChangeFlags=0;
}