nus-yam/ex-repair huggingface dataset:
Program: 2137
Project: 2137
Buggy source:
@Override public boolean isGoneForLayoutLw(){
  final AppWindowToken atoken=mAppToken;
  return mViewVisibility == View.GONE || !mRelayoutCalled || (atoken == null && mRootToken.hidden) || (atoken != null && (atoken.hiddenRequested || atoken.hidden)) || mAttachedHidden || mExiting || mDestroying;
}

Fixed version (ground truth):
@Override public boolean isGoneForLayoutLw(){
  final AppWindowToken atoken=mAppToken;
  return mViewVisibility == View.GONE || !mRelayoutCalled || (atoken == null && mRootToken.hidden) || (atoken != null && (atoken.hiddenRequested || atoken.hidden)) || mAttachedHidden || (mExiting && !isAnimatingLw()) || mDestroying;
}
Program: 2138
Project: 2138
Buggy source:
void reportActivityLaunchedLocked(boolean timeout,ActivityRecord r,long thisTime,long totalTime){
  for (int i=mWaitingActivityLaunched.size() - 1; i >= 0; i--) {
    WaitResult w=mWaitingActivityLaunched.get(i);
    w.timeout=timeout;
    if (r != null) {
      w.who=new ComponentName(r.info.packageName,r.info.name);
    }
    w.thisTime=thisTime;
    w.totalTime=totalTime;
  }
  mService.notifyAll();
}

Fixed version (ground truth):
void reportActivityLaunchedLocked(boolean timeout,ActivityRecord r,long thisTime,long totalTime){
  for (int i=mWaitingActivityLaunched.size() - 1; i >= 0; i--) {
    WaitResult w=mWaitingActivityLaunched.remove(i);
    w.timeout=timeout;
    if (r != null) {
      w.who=new ComponentName(r.info.packageName,r.info.name);
    }
    w.thisTime=thisTime;
    w.totalTime=totalTime;
  }
  mService.notifyAll();
}
Program: 2139
Project: 2139
Buggy source:
void scheduleIdleTimeoutLocked(ActivityRecord next){
  mHandler.obtainMessage(IDLE_TIMEOUT_MSG,next).sendToTarget();
}

Fixed version (ground truth):
void scheduleIdleTimeoutLocked(ActivityRecord next){
  Message msg=mHandler.obtainMessage(IDLE_TIMEOUT_MSG,next);
  mHandler.sendMessageDelayed(msg,IDLE_TIMEOUT);
}
Program: 2140
Project: 2140
Buggy source:
void reportActivityLaunchedLocked(boolean timeout,ActivityRecord r,long thisTime,long totalTime){
  for (int i=mWaitingActivityLaunched.size() - 1; i >= 0; i--) {
    WaitResult w=mWaitingActivityLaunched.get(i);
    w.timeout=timeout;
    if (r != null) {
      w.who=new ComponentName(r.info.packageName,r.info.name);
    }
    w.thisTime=thisTime;
    w.totalTime=totalTime;
  }
  mService.notifyAll();
}

Fixed version (ground truth):
void reportActivityLaunchedLocked(boolean timeout,ActivityRecord r,long thisTime,long totalTime){
  for (int i=mWaitingActivityLaunched.size() - 1; i >= 0; i--) {
    WaitResult w=mWaitingActivityLaunched.remove(i);
    w.timeout=timeout;
    if (r != null) {
      w.who=new ComponentName(r.info.packageName,r.info.name);
    }
    w.thisTime=thisTime;
    w.totalTime=totalTime;
  }
  mService.notifyAll();
}
Program: 2141
Project: 2141
Buggy source:
void scheduleIdleTimeoutLocked(ActivityRecord next){
  mHandler.obtainMessage(IDLE_TIMEOUT_MSG,next).sendToTarget();
}

Fixed version (ground truth):
void scheduleIdleTimeoutLocked(ActivityRecord next){
  Message msg=mHandler.obtainMessage(IDLE_TIMEOUT_MSG,next);
  mHandler.sendMessageDelayed(msg,IDLE_TIMEOUT);
}
Program: 2143
Project: 2143
Buggy source:
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo();
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}

Fixed version (ground truth):
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo(true);
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}
Program: 2145
Project: 2145
Buggy source:
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (TextUtils.isEmpty(getContentDescription()) && !TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}

Fixed version (ground truth):
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (!TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}
Program: 2146
Project: 2146
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionStart=getSelectionStart();
    if (selectionStart >= 0) {
      return selectionStart;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  return getSelectionStart();
}
Program: 2147
Project: 2147
Buggy source:
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!TextUtils.isEmpty(mText)) {
    if (!(mText instanceof Spannable)) {
      setText(mText,BufferType.SPANNABLE);
    }
    return mText;
  }
  return super.getIterableTextForAccessibility();
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!(mText instanceof Spannable)) {
    setText(mText,BufferType.SPANNABLE);
  }
  return mText;
}
Program: 2148
Project: 2148
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionEnd=getSelectionEnd();
    if (selectionEnd >= 0) {
      return selectionEnd;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  return getSelectionEnd();
}
Program: 2149
Project: 2149
Buggy source:
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  if (mResolveInfo != null) {
    mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
    mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
    mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
  }
}

Fixed version (ground truth):
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
  mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
  mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
}
Program: 2152
Project: 2152
Buggy source:
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo();
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}

Fixed version (ground truth):
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo(true);
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}
Program: 2154
Project: 2154
Buggy source:
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (TextUtils.isEmpty(getContentDescription()) && !TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}

Fixed version (ground truth):
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (!TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}
Program: 2155
Project: 2155
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionStart=getSelectionStart();
    if (selectionStart >= 0) {
      return selectionStart;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  return getSelectionStart();
}
Program: 2156
Project: 2156
Buggy source:
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!TextUtils.isEmpty(mText)) {
    if (!(mText instanceof Spannable)) {
      setText(mText,BufferType.SPANNABLE);
    }
    return mText;
  }
  return super.getIterableTextForAccessibility();
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!(mText instanceof Spannable)) {
    setText(mText,BufferType.SPANNABLE);
  }
  return mText;
}
Program: 2157
Project: 2157
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionEnd=getSelectionEnd();
    if (selectionEnd >= 0) {
      return selectionEnd;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  return getSelectionEnd();
}
Program: 2158
Project: 2158
Buggy source:
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  if (mResolveInfo != null) {
    mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
    mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
    mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
  }
}

Fixed version (ground truth):
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
  mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
  mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
}
Program: 2161
Project: 2161
Buggy source:
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo();
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}

Fixed version (ground truth):
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo(true);
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}
Program: 2163
Project: 2163
Buggy source:
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (TextUtils.isEmpty(getContentDescription()) && !TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}

Fixed version (ground truth):
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (!TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}
Program: 2164
Project: 2164
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionStart=getSelectionStart();
    if (selectionStart >= 0) {
      return selectionStart;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  return getSelectionStart();
}
Program: 2165
Project: 2165
Buggy source:
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!TextUtils.isEmpty(mText)) {
    if (!(mText instanceof Spannable)) {
      setText(mText,BufferType.SPANNABLE);
    }
    return mText;
  }
  return super.getIterableTextForAccessibility();
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!(mText instanceof Spannable)) {
    setText(mText,BufferType.SPANNABLE);
  }
  return mText;
}
Program: 2166
Project: 2166
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionEnd=getSelectionEnd();
    if (selectionEnd >= 0) {
      return selectionEnd;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  return getSelectionEnd();
}
Program: 2167
Project: 2167
Buggy source:
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  if (mResolveInfo != null) {
    mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
    mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
    mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
  }
}

Fixed version (ground truth):
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
  mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
  mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
}
Program: 2170
Project: 2170
Buggy source:
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo();
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}

Fixed version (ground truth):
private void registerUiTestAutomationServiceLocked(IAccessibilityServiceClient client){
  IAccessibilityManager manager=IAccessibilityManager.Stub.asInterface(ServiceManager.getService(Context.ACCESSIBILITY_SERVICE));
  AccessibilityServiceInfo info=new AccessibilityServiceInfo(true);
  info.eventTypes=AccessibilityEvent.TYPES_ALL_MASK;
  info.feedbackType=AccessibilityServiceInfo.FEEDBACK_GENERIC;
  info.flags|=AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS | AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS;
  try {
    manager.registerUiTestAutomationService(mToken,client,info);
    mClient=client;
  }
 catch (  RemoteException re) {
    throw new IllegalStateException("String_Node_Str",re);
  }
}
Program: 2172
Project: 2172
Buggy source:
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (TextUtils.isEmpty(getContentDescription()) && !TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}

Fixed version (ground truth):
@Override public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info){
  super.onInitializeAccessibilityNodeInfo(info);
  info.setClassName(TextView.class.getName());
  final boolean isPassword=hasPasswordTransformationMethod();
  info.setPassword(isPassword);
  if (!isPassword) {
    info.setText(getTextForAccessibility());
  }
  if (mBufferType == BufferType.EDITABLE) {
    info.setEditable(true);
  }
  if (!TextUtils.isEmpty(mText)) {
    info.addAction(AccessibilityNodeInfo.ACTION_NEXT_AT_MOVEMENT_GRANULARITY);
    info.addAction(AccessibilityNodeInfo.ACTION_PREVIOUS_AT_MOVEMENT_GRANULARITY);
    info.setMovementGranularities(AccessibilityNodeInfo.MOVEMENT_GRANULARITY_CHARACTER | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_WORD | AccessibilityNodeInfo.MOVEMENT_GRANULARITY_LINE| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PARAGRAPH| AccessibilityNodeInfo.MOVEMENT_GRANULARITY_PAGE);
  }
  if (isFocused()) {
    if (canSelectText()) {
      info.addAction(AccessibilityNodeInfo.ACTION_SET_SELECTION);
    }
    if (canCopy()) {
      info.addAction(AccessibilityNodeInfo.ACTION_COPY);
    }
    if (canPaste()) {
      info.addAction(AccessibilityNodeInfo.ACTION_PASTE);
    }
    if (canCut()) {
      info.addAction(AccessibilityNodeInfo.ACTION_CUT);
    }
  }
}
Program: 2173
Project: 2173
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionStart=getSelectionStart();
    if (selectionStart >= 0) {
      return selectionStart;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionStart(){
  return getSelectionStart();
}
Program: 2174
Project: 2174
Buggy source:
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!TextUtils.isEmpty(mText)) {
    if (!(mText instanceof Spannable)) {
      setText(mText,BufferType.SPANNABLE);
    }
    return mText;
  }
  return super.getIterableTextForAccessibility();
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public CharSequence getIterableTextForAccessibility(){
  if (!(mText instanceof Spannable)) {
    setText(mText,BufferType.SPANNABLE);
  }
  return mText;
}
Program: 2175
Project: 2175
Buggy source:
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  if (TextUtils.isEmpty(getContentDescription())) {
    final int selectionEnd=getSelectionEnd();
    if (selectionEnd >= 0) {
      return selectionEnd;
    }
  }
  return ACCESSIBILITY_CURSOR_POSITION_UNDEFINED;
}

Fixed version (ground truth):
/** 
 * @hide
 */
@Override public int getAccessibilitySelectionEnd(){
  return getSelectionEnd();
}
Program: 2176
Project: 2176
Buggy source:
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  if (mResolveInfo != null) {
    mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
    mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
    mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
  }
}

Fixed version (ground truth):
public void setDynamicallyConfigurableProperties(AccessibilityServiceInfo info){
  mEventTypes=info.eventTypes;
  mFeedbackType=info.feedbackType;
  String[] packageNames=info.packageNames;
  if (packageNames != null) {
    mPackageNames.addAll(Arrays.asList(packageNames));
  }
  mNotificationTimeout=info.notificationTimeout;
  mIsDefault=(info.flags & DEFAULT) != 0;
  if (mIsAutomation || info.getResolveInfo().serviceInfo.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.JELLY_BEAN) {
    if ((info.flags & AccessibilityServiceInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS) != 0) {
      mFetchFlags|=AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
 else {
      mFetchFlags&=~AccessibilityNodeInfo.FLAG_INCLUDE_NOT_IMPORTANT_VIEWS;
    }
  }
  if ((info.flags & AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS) != 0) {
    mFetchFlags|=AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
 else {
    mFetchFlags&=~AccessibilityNodeInfo.FLAG_REPORT_VIEW_IDS;
  }
  mRequestTouchExplorationMode=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_TOUCH_EXPLORATION_MODE) != 0;
  mRequestEnhancedWebAccessibility=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_ENHANCED_WEB_ACCESSIBILITY) != 0;
  mRequestFilterKeyEvents=(info.flags & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
}
Program: 2178
Project: 2178
Buggy source:
/** 
 * Apply this Builder to an existing   {@link Notification} object.
 * @hide
 */
public Notification buildInto(Notification n){
  build().cloneInto(n);
  return n;
}

Fixed version (ground truth):
/** 
 * Apply this Builder to an existing   {@link Notification} object.
 * @hide
 */
public Notification buildInto(Notification n){
  build().cloneInto(n,true);
  return n;
}
Program: 2180
Project: 2180
Buggy source:
@Override public Notification clone(){
  Notification that=new Notification();
  cloneInto(that);
  return that;
}

Fixed version (ground truth):
@Override public Notification clone(){
  Notification that=new Notification();
  cloneInto(that,true);
  return that;
}
Program: 2181
Project: 2181
Buggy source:
@Override public void run(){
  info.notifyRemovedIfUserMatch(sbn);
}

Fixed version (ground truth):
@Override public void run(){
  info.notifyRemovedIfUserMatch(sbn_light);
}
Program: 2182
Project: 2182
Buggy source:
public void record(StatusBarNotification nr){
  nr.notification.tickerView=null;
  nr.notification.contentView=null;
  nr.notification.bigContentView=null;
  nr.notification.largeIcon=null;
  final Bundle extras=nr.notification.extras;
  extras.remove(Notification.EXTRA_LARGE_ICON);
  extras.remove(Notification.EXTRA_LARGE_ICON_BIG);
  extras.remove(Notification.EXTRA_PICTURE);
  if (mBuffer.size() == BUFFER_SIZE) {
    mBuffer.removeFirst();
  }
  mBuffer.addLast(nr);
}

Fixed version (ground truth):
public void record(StatusBarNotification nr){
  nr.notification.lightenPayload();
  if (mBuffer.size() == BUFFER_SIZE) {
    mBuffer.removeFirst();
  }
  mBuffer.addLast(nr);
}
Program: 2183
Project: 2183
Buggy source:
public void notifyRemovedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn))   return;
  try {
    listener.onNotificationRemoved(sbn);
  }
 catch (  RemoteException ex) {
  }
}

Fixed version (ground truth):
public void notifyRemovedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn))   return;
  try {
    listener.onNotificationRemoved(sbn);
  }
 catch (  RemoteException ex) {
    Log.e(TAG,"String_Node_Str" + listener,ex);
  }
}
Program: 2184
Project: 2184
Buggy source:
/** 
 * asynchronously notify all listeners about a new notification
 */
private void notifyPostedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn;
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyPostedIfUserMatch(sbn);
      }
    }
);
  }
}

Fixed version (ground truth):
/** 
 * asynchronously notify all listeners about a new notification
 */
private void notifyPostedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn.clone();
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyPostedIfUserMatch(sbn);
      }
    }
);
  }
}
Program: 2185
Project: 2185
Buggy source:
/** 
 * asynchronously notify all listeners about a removed notification
 */
private void notifyRemovedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn;
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyRemovedIfUserMatch(sbn);
      }
    }
);
  }
}

Fixed version (ground truth):
/** 
 * asynchronously notify all listeners about a removed notification
 */
private void notifyRemovedLocked(NotificationRecord n){
  final StatusBarNotification sbn_light=n.sbn.cloneLight();
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyRemovedIfUserMatch(sbn_light);
      }
    }
);
  }
}
Program: 2186
Project: 2186
Buggy source:
public void notifyPostedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn)) {
    return;
  }
  try {
    listener.onNotificationPosted(sbn);
  }
 catch (  RemoteException ex) {
  }
}

Fixed version (ground truth):
public void notifyPostedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn)) {
    return;
  }
  try {
    listener.onNotificationPosted(sbn);
  }
 catch (  RemoteException ex) {
    Log.e(TAG,"String_Node_Str" + listener,ex);
  }
}
Program: 2187
Project: 2187
Buggy source:
/** 
 * Apply this Builder to an existing   {@link Notification} object.
 * @hide
 */
public Notification buildInto(Notification n){
  build().cloneInto(n);
  return n;
}

Fixed version (ground truth):
/** 
 * Apply this Builder to an existing   {@link Notification} object.
 * @hide
 */
public Notification buildInto(Notification n){
  build().cloneInto(n,true);
  return n;
}
Program: 2189
Project: 2189
Buggy source:
@Override public Notification clone(){
  Notification that=new Notification();
  cloneInto(that);
  return that;
}

Fixed version (ground truth):
@Override public Notification clone(){
  Notification that=new Notification();
  cloneInto(that,true);
  return that;
}
Program: 2190
Project: 2190
Buggy source:
@Override public void run(){
  info.notifyRemovedIfUserMatch(sbn);
}

Fixed version (ground truth):
@Override public void run(){
  info.notifyRemovedIfUserMatch(sbn_light);
}
Program: 2191
Project: 2191
Buggy source:
public void record(StatusBarNotification nr){
  nr.notification.tickerView=null;
  nr.notification.contentView=null;
  nr.notification.bigContentView=null;
  nr.notification.largeIcon=null;
  final Bundle extras=nr.notification.extras;
  extras.remove(Notification.EXTRA_LARGE_ICON);
  extras.remove(Notification.EXTRA_LARGE_ICON_BIG);
  extras.remove(Notification.EXTRA_PICTURE);
  if (mBuffer.size() == BUFFER_SIZE) {
    mBuffer.removeFirst();
  }
  mBuffer.addLast(nr);
}

Fixed version (ground truth):
public void record(StatusBarNotification nr){
  nr.notification.lightenPayload();
  if (mBuffer.size() == BUFFER_SIZE) {
    mBuffer.removeFirst();
  }
  mBuffer.addLast(nr);
}
Program: 2192
Project: 2192
Buggy source:
public void notifyRemovedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn))   return;
  try {
    listener.onNotificationRemoved(sbn);
  }
 catch (  RemoteException ex) {
  }
}

Fixed version (ground truth):
public void notifyRemovedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn))   return;
  try {
    listener.onNotificationRemoved(sbn);
  }
 catch (  RemoteException ex) {
    Log.e(TAG,"String_Node_Str" + listener,ex);
  }
}
Program: 2193
Project: 2193
Buggy source:
/** 
 * asynchronously notify all listeners about a new notification
 */
private void notifyPostedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn;
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyPostedIfUserMatch(sbn);
      }
    }
);
  }
}

Fixed version (ground truth):
/** 
 * asynchronously notify all listeners about a new notification
 */
private void notifyPostedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn.clone();
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyPostedIfUserMatch(sbn);
      }
    }
);
  }
}
Program: 2194
Project: 2194
Buggy source:
/** 
 * asynchronously notify all listeners about a removed notification
 */
private void notifyRemovedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn;
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyRemovedIfUserMatch(sbn);
      }
    }
);
  }
}

Fixed version (ground truth):
/** 
 * asynchronously notify all listeners about a removed notification
 */
private void notifyRemovedLocked(NotificationRecord n){
  final StatusBarNotification sbn_light=n.sbn.cloneLight();
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyRemovedIfUserMatch(sbn_light);
      }
    }
);
  }
}
Program: 2195
Project: 2195
Buggy source:
public void notifyPostedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn)) {
    return;
  }
  try {
    listener.onNotificationPosted(sbn);
  }
 catch (  RemoteException ex) {
  }
}

Fixed version (ground truth):
public void notifyPostedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn)) {
    return;
  }
  try {
    listener.onNotificationPosted(sbn);
  }
 catch (  RemoteException ex) {
    Log.e(TAG,"String_Node_Str" + listener,ex);
  }
}
Program: 2196
Project: 2196
Buggy source:
/** 
 * Apply this Builder to an existing   {@link Notification} object.
 * @hide
 */
public Notification buildInto(Notification n){
  build().cloneInto(n);
  return n;
}

Fixed version (ground truth):
/** 
 * Apply this Builder to an existing   {@link Notification} object.
 * @hide
 */
public Notification buildInto(Notification n){
  build().cloneInto(n,true);
  return n;
}
Program: 2198
Project: 2198
Buggy source:
@Override public Notification clone(){
  Notification that=new Notification();
  cloneInto(that);
  return that;
}

Fixed version (ground truth):
@Override public Notification clone(){
  Notification that=new Notification();
  cloneInto(that,true);
  return that;
}
Program: 2199
Project: 2199
Buggy source:
@Override public void run(){
  info.notifyRemovedIfUserMatch(sbn);
}

Fixed version (ground truth):
@Override public void run(){
  info.notifyRemovedIfUserMatch(sbn_light);
}
Program: 2200
Project: 2200
Buggy source:
public void record(StatusBarNotification nr){
  nr.notification.tickerView=null;
  nr.notification.contentView=null;
  nr.notification.bigContentView=null;
  nr.notification.largeIcon=null;
  final Bundle extras=nr.notification.extras;
  extras.remove(Notification.EXTRA_LARGE_ICON);
  extras.remove(Notification.EXTRA_LARGE_ICON_BIG);
  extras.remove(Notification.EXTRA_PICTURE);
  if (mBuffer.size() == BUFFER_SIZE) {
    mBuffer.removeFirst();
  }
  mBuffer.addLast(nr);
}

Fixed version (ground truth):
public void record(StatusBarNotification nr){
  nr.notification.lightenPayload();
  if (mBuffer.size() == BUFFER_SIZE) {
    mBuffer.removeFirst();
  }
  mBuffer.addLast(nr);
}
Program: 2201
Project: 2201
Buggy source:
public void notifyRemovedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn))   return;
  try {
    listener.onNotificationRemoved(sbn);
  }
 catch (  RemoteException ex) {
  }
}

Fixed version (ground truth):
public void notifyRemovedIfUserMatch(StatusBarNotification sbn){
  if (!enabledAndUserMatches(sbn))   return;
  try {
    listener.onNotificationRemoved(sbn);
  }
 catch (  RemoteException ex) {
    Log.e(TAG,"String_Node_Str" + listener,ex);
  }
}
Program: 2202
Project: 2202
Buggy source:
/** 
 * asynchronously notify all listeners about a new notification
 */
private void notifyPostedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn;
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyPostedIfUserMatch(sbn);
      }
    }
);
  }
}

Fixed version (ground truth):
/** 
 * asynchronously notify all listeners about a new notification
 */
private void notifyPostedLocked(NotificationRecord n){
  final StatusBarNotification sbn=n.sbn.clone();
  for (  final NotificationListenerInfo info : mListeners) {
    mHandler.post(new Runnable(){
      @Override public void run(){
        info.notifyPostedIfUserMatch(sbn);
      }
    }
);
  }
}