nus-yam/ex-repair huggingface dataset:
Program: 44644
Project: 44644
Buggy source:
private void launchTransaction(int serviceId,TransactionBundle txnBundle,boolean noNetwork){
  if (noNetwork) {
    Log.w(TAG,"String_Node_Str");
    onNetworkUnavailable(serviceId,txnBundle.getTransactionType());
    return;
  }
  Message msg=mServiceHandler.obtainMessage(EVENT_TRANSACTION_REQUEST);
  msg.arg1=serviceId;
  msg.obj=txnBundle;
  if (Log.isLoggable(MmsApp.LOG_TAG,Log.VERBOSE)) {
    Log.v(TAG,"String_Node_Str" + msg);
  }
  mServiceHandler.sendMessage(msg);
  Recycler.getMmsRecycler().deleteOldMessages(getApplicationContext());
}

Fixed version (ground truth):
private void launchTransaction(int serviceId,TransactionBundle txnBundle,boolean noNetwork){
  if (noNetwork) {
    Log.w(TAG,"String_Node_Str");
    onNetworkUnavailable(serviceId,txnBundle.getTransactionType());
    return;
  }
  Message msg=mServiceHandler.obtainMessage(EVENT_TRANSACTION_REQUEST);
  msg.arg1=serviceId;
  msg.obj=txnBundle;
  if (Log.isLoggable(MmsApp.LOG_TAG,Log.VERBOSE)) {
    Log.v(TAG,"String_Node_Str" + msg);
  }
  mServiceHandler.sendMessage(msg);
}
Program: 44646
Project: 44646
Buggy source:
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  requestWindowFeature(Window.FEATURE_PROGRESS);
  requestWindowFeature(Window.FEATURE_LEFT_ICON);
  setContentView(R.layout.compose_message_activity);
  setProgressBarVisibility(false);
  setTitle("String_Node_Str");
  initResourceRefs();
  mContentResolver=getContentResolver();
  mBackgroundQueryHandler=new BackgroundQueryHandler(mContentResolver);
  mWorkingMessage=WorkingMessage.createEmpty(this);
  initActivityState(savedInstanceState,getIntent());
  if (LOCAL_LOGV) {
    Log.v(TAG,"String_Node_Str" + savedInstanceState);
    Log.v(TAG,"String_Node_Str" + getIntent());
  }
  if (cancelFailedToDeliverNotification(getIntent(),getApplicationContext())) {
    undeliveredMessageDialog(getMessageDate(null));
  }
  initMessageList();
  mConversation.markAsRead();
  if (!handleSendIntent(getIntent()) && !handleForwardedMessage()) {
    loadDraft();
  }
  mWorkingMessage.setConversation(mConversation);
  if (mConversation.getThreadId() <= 0) {
    initRecipientsEditor();
  }
  updateSendButtonState();
  drawTopPanel();
  drawBottomPanel();
  mAttachmentEditor.update(mWorkingMessage);
  Configuration config=getResources().getConfiguration();
  mIsKeyboardOpen=config.keyboardHidden == KEYBOARDHIDDEN_NO;
  mIsLandscape=config.orientation == Configuration.ORIENTATION_LANDSCAPE;
  onKeyboardStateChanged(mIsKeyboardOpen);
  if (TRACE) {
    android.os.Debug.startMethodTracing("String_Node_Str");
  }
}

Fixed version (ground truth):
@Override protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  requestWindowFeature(Window.FEATURE_PROGRESS);
  requestWindowFeature(Window.FEATURE_LEFT_ICON);
  setContentView(R.layout.compose_message_activity);
  setProgressBarVisibility(false);
  setTitle("String_Node_Str");
  initResourceRefs();
  mContentResolver=getContentResolver();
  mBackgroundQueryHandler=new BackgroundQueryHandler(mContentResolver);
  mWorkingMessage=WorkingMessage.createEmpty(this);
  initActivityState(savedInstanceState,getIntent());
  if (LOCAL_LOGV) {
    Log.v(TAG,"String_Node_Str" + savedInstanceState);
    Log.v(TAG,"String_Node_Str" + getIntent());
  }
  if (cancelFailedToDeliverNotification(getIntent(),this)) {
    undeliveredMessageDialog(getMessageDate(null));
  }
  cancelFailedDownloadNotification(getIntent(),this);
  initMessageList();
  mConversation.markAsRead();
  if (!handleSendIntent(getIntent()) && !handleForwardedMessage()) {
    loadDraft();
  }
  mWorkingMessage.setConversation(mConversation);
  if (mConversation.getThreadId() <= 0) {
    initRecipientsEditor();
  }
  updateSendButtonState();
  drawTopPanel();
  drawBottomPanel();
  mAttachmentEditor.update(mWorkingMessage);
  Configuration config=getResources().getConfiguration();
  mIsKeyboardOpen=config.keyboardHidden == KEYBOARDHIDDEN_NO;
  mIsLandscape=config.orientation == Configuration.ORIENTATION_LANDSCAPE;
  onKeyboardStateChanged(mIsKeyboardOpen);
  if (TRACE) {
    android.os.Debug.startMethodTracing("String_Node_Str");
  }
}
Program: 44647
Project: 44647
Buggy source:
static public boolean cancelFailedToDeliverNotification(Intent intent,Context context){
  if (ConversationList.isFailedToDeliver(intent)) {
    MessagingNotification.cancelNotification(context,MessagingNotification.MESSAGE_FAILED_NOTIFICATION_ID);
    return true;
  }
  return false;
}

Fixed version (ground truth):
public static boolean cancelFailedToDeliverNotification(Intent intent,Context context){
  if (MessagingNotification.isFailedToDeliver(intent)) {
    MessagingNotification.cancelNotification(context,MessagingNotification.MESSAGE_FAILED_NOTIFICATION_ID);
    return true;
  }
  return false;
}
Program: 44648
Project: 44648
Buggy source:
@Override public void onChange(boolean selfUpdate){
  mCachedNames.clear();
}

Fixed version (ground truth):
@Override public void onChange(boolean selfUpdate){
  mCachedNames.clear();
  mListAdapter.invalidateAddressCache();
}
Program: 44649
Project: 44649
Buggy source:
public CachingNameStoreImpl(Context ctxt){
  mContext=ctxt;
  mPhonesObserver=new ContentObserver(new Handler()){
    @Override public void onChange(    boolean selfUpdate){
      mCachedNames.clear();
    }
  }
;
  ctxt.getContentResolver().registerContentObserver(Contacts.Phones.CONTENT_URI,true,mPhonesObserver);
}

Fixed version (ground truth):
public CachingNameStoreImpl(Context ctxt){
  mPhonesObserver=new ContentObserver(new Handler()){
    @Override public void onChange(    boolean selfUpdate){
      mCachedNames.clear();
      mListAdapter.invalidateAddressCache();
    }
  }
;
  ctxt.getContentResolver().registerContentObserver(People.CONTENT_URI,true,mPhonesObserver);
}
Program: 44650
Project: 44650
Buggy source:
public static Intent createAddContactIntent(String address){
  Intent intent=new Intent(Intent.ACTION_INSERT_OR_EDIT);
  intent.setType(Contacts.People.CONTENT_ITEM_TYPE);
  if (Recipient.isPhoneNumber(address)) {
    intent.putExtra(Insert.PHONE,address);
  }
 else {
    intent.putExtra(Insert.EMAIL,address);
  }
  intent.putExtra(Insert.NAME,address);
  return intent;
}

Fixed version (ground truth):
public static Intent createAddContactIntent(String address){
  Intent intent=new Intent(Intent.ACTION_INSERT_OR_EDIT);
  intent.setType(Contacts.People.CONTENT_ITEM_TYPE);
  if (Recipient.isPhoneNumber(address)) {
    intent.putExtra(Insert.PHONE,address);
  }
 else {
    intent.putExtra(Insert.EMAIL,address);
  }
  return intent;
}
Program: 44651
Project: 44651
Buggy source:
public static Intent createAddContactIntent(String address){
  Intent intent=new Intent(Intent.ACTION_INSERT_OR_EDIT);
  intent.setType(Contacts.People.CONTENT_ITEM_TYPE);
  if (Recipient.isPhoneNumber(address)) {
    intent.putExtra(Insert.PHONE,address);
  }
 else {
    intent.putExtra(Insert.EMAIL,address);
  }
  intent.putExtra(Insert.NAME,address);
  return intent;
}

Fixed version (ground truth):
public static Intent createAddContactIntent(String address){
  Intent intent=new Intent(Intent.ACTION_INSERT_OR_EDIT);
  intent.setType(Contacts.People.CONTENT_ITEM_TYPE);
  if (Recipient.isPhoneNumber(address)) {
    intent.putExtra(Insert.PHONE,address);
  }
 else {
    intent.putExtra(Insert.EMAIL,address);
  }
  return intent;
}
Program: 44652
Project: 44652
Buggy source:
public static Intent createAddContactIntent(String address){
  Intent intent=new Intent(Intent.ACTION_INSERT_OR_EDIT);
  intent.setType(Contacts.People.CONTENT_ITEM_TYPE);
  if (Recipient.isPhoneNumber(address)) {
    intent.putExtra(Insert.PHONE,address);
  }
 else {
    intent.putExtra(Insert.EMAIL,address);
  }
  intent.putExtra(Insert.NAME,address);
  return intent;
}

Fixed version (ground truth):
public static Intent createAddContactIntent(String address){
  Intent intent=new Intent(Intent.ACTION_INSERT_OR_EDIT);
  intent.setType(Contacts.People.CONTENT_ITEM_TYPE);
  if (Recipient.isPhoneNumber(address)) {
    intent.putExtra(Insert.PHONE,address);
  }
 else {
    intent.putExtra(Insert.EMAIL,address);
  }
  return intent;
}
Program: 44657
Project: 44657
Buggy source:
public static String getPKGNameFromAddr(Context cxt,String localIP,int localPort,String remoteIP,int remotePort){
  if (AppNameQueryEngine.isValidQuery(remoteIP,remotePort,localPort) == false)   return null;
  String knownService=AppNameQueryEngine.queryServiceByPort(remotePort);
  if (knownService != null)   return knownService;
  int uid=-1;
  String networkAddr=toString(remoteIP,remotePort,localPort);
  if (connectionCache.contains(networkAddr)) {
    uid=connectionCache.get(networkAddr).uid;
  }
 else {
    debugInfo="String_Node_Str";
    for (int i=0; i < 3; i++) {
      uid=getConnectionUid(localIP,localPort,remoteIP,remotePort);
      Log.d(TAG,"String_Node_Str" + uid);
      if (uid >= 0) {
        break;
      }
 else {
        try {
          Thread.sleep(5);
        }
 catch (        InterruptedException e) {
          e.printStackTrace();
        }
        Log.d(TAG,"String_Node_Str" + i + "String_Node_Str"+ networkAddr+ "String_Node_Str");
        Log.d(TAG,debugInfo);
        Log.d(TAG,"String_Node_Str");
      }
    }
    if (uid < 0)     return null;
    connectionCache.put(networkAddr,new ConnectionCacheItem(uid));
  }
  if (monitorThread == null || monitorThread.isAlive() == false) {
    monitorThread=new Thread(new CacheMonitor());
    monitorThread.start();
  }
  if (uid2PkgName.containsKey(uid) == false) {
    refreshCache(cxt,uid);
  }
  return uid2PkgName.get(uid);
}

Fixed version (ground truth):
public static String getPKGNameFromAddr(Context cxt,String localIP,int localPort,String remoteIP,int remotePort){
  if (AppNameQueryEngine.isValidQuery(remoteIP,remotePort,localPort) == false)   return null;
  String knownService=AppNameQueryEngine.queryServiceByPort(remotePort);
  if (knownService != null)   return knownService;
  if (localPort == skypeInfo.listenPort)   return skypeInfo.pkgName;
  int uid=-1;
  String networkAddr=toString(remoteIP,remotePort,localPort);
  if (connectionCache.contains(networkAddr)) {
    uid=connectionCache.get(networkAddr).uid;
  }
 else {
    debugInfo="String_Node_Str";
    uid=getConnectionUid(localIP,localPort,remoteIP,remotePort);
  }
  if (uid < 0)   return null;
  connectionCache.put(networkAddr,new ConnectionCacheItem(uid));
  if (monitorThread == null || monitorThread.isAlive() == false) {
    monitorThread=new Thread(new CacheMonitor());
    monitorThread.start();
  }
  if (uid2PkgName.containsKey(uid) == false) {
    refreshCache(cxt,uid);
  }
  return uid2PkgName.get(uid);
}
Program: 44658
Project: 44658
Buggy source:
public static int getUidFromFile(String localAddr,String remoteAddr,String file){
  ArrayList<String> lines=Utility.readLinesFromFile(file);
  int uid=-1;
  debugInfo+="String_Node_Str" + localAddr + "String_Node_Str"+ remoteAddr+ "String_Node_Str"+ file+ "String_Node_Str";
  for (  String line : lines) {
    debugInfo+=line + "String_Node_Str";
    try {
      String[] items=line.split("String_Node_Str");
      if (items[1].equalsIgnoreCase(localAddr) && items[2].equalsIgnoreCase(remoteAddr)) {
        debugInfo+="String_Node_Str" + items[7];
        uid=Integer.parseInt(items[7]);
        debugInfo+="String_Node_Str" + uid + "String_Node_Str";
        break;
      }
    }
 catch (    Exception e) {
      Log.d(TAG,"String_Node_Str" + e.getMessage());
    }
  }
  return uid;
}

Fixed version (ground truth):
public static int getUidFromFile(String localAddr,String remoteAddr,String file){
  ArrayList<String> lines=Utility.readLinesFromFile(file);
  int uid=-1;
  for (  String line : lines) {
    try {
      String[] items=line.split("String_Node_Str");
      if (items[1].equalsIgnoreCase(localAddr) && items[2].equalsIgnoreCase(remoteAddr)) {
        uid=Integer.parseInt(items[7]);
        break;
      }
    }
 catch (    Exception e) {
      Log.d(TAG,"String_Node_Str" + e.getMessage());
    }
  }
  return uid;
}
Program: 44659
Project: 44659
Buggy source:
public static void refreshCache(Context cxt,int uid){
  if (SystemService.id2Service.containsKey(uid)) {
    uid2PkgName.put(uid,SystemService.id2Service.get(uid));
  }
 else {
    PackageManager pm=cxt.getPackageManager();
    List<ApplicationInfo> packages=pm.getInstalledApplications(PackageManager.GET_META_DATA);
    for (int i=0; i < packages.size(); i++) {
      ApplicationInfo appInfo=packages.get(i);
      if (!uid2PkgName.containsKey(appInfo.uid)) {
        uid2PkgName.put(appInfo.uid,appInfo.processName);
      }
    }
  }
  if (uid2PkgName.containsKey(uid) == false) {
    uid2PkgName.put(uid,"String_Node_Str" + uid);
  }
}

Fixed version (ground truth):
public static void refreshCache(Context cxt,int uid){
  if (SystemService.id2Service.containsKey(uid)) {
    uid2PkgName.put(uid,SystemService.id2Service.get(uid));
  }
 else {
    PackageManager pm=cxt.getPackageManager();
    List<ApplicationInfo> packages=pm.getInstalledApplications(PackageManager.GET_META_DATA);
    for (int i=0; i < packages.size(); i++) {
      ApplicationInfo appInfo=packages.get(i);
      if (!uid2PkgName.containsKey(appInfo.uid)) {
        uid2PkgName.put(appInfo.uid,appInfo.processName);
      }
      if (appInfo.processName.contains("String_Node_Str")) {
        skypeInfo.dataDir=appInfo.dataDir;
        skypeInfo.pkgName=appInfo.processName;
        skypeInfo.uid=appInfo.uid;
        skypeInfo.getListenPort();
      }
    }
  }
  if (uid2PkgName.containsKey(uid) == false) {
    uid2PkgName.put(uid,"String_Node_Str" + uid);
  }
}
Program: 44660
Project: 44660
Buggy source:
public static String getPKGNameFromAddr(Context cxt,String localIP,int localPort,String remoteIP,int remotePort){
  if (AppNameQueryEngine.isValidQuery(remoteIP,remotePort,localPort) == false)   return null;
  String knownService=AppNameQueryEngine.queryServiceByPort(remotePort);
  if (knownService != null)   return knownService;
  int uid=-1;
  if (connectionCache.contains(toString(remoteIP,remotePort,localPort))) {
    uid=connectionCache.get(toString(remoteIP,remotePort,localPort)).uid;
  }
 else {
    uid=getConnectionUid(localIP,localPort,remoteIP,remotePort);
    if (uid < 0)     return null;
    connectionCache.put(toString(remoteIP,remotePort,localPort),new ConnectionCacheItem(uid));
  }
  if (monitorThread == null || monitorThread.isAlive() == false) {
    monitorThread=new Thread(new CacheMonitor());
    monitorThread.start();
  }
  if (uid2PkgName.containsKey(uid) == false) {
    refreshCache(cxt,uid);
  }
  return uid2PkgName.get(uid);
}

Fixed version (ground truth):
public static String getPKGNameFromAddr(Context cxt,String localIP,int localPort,String remoteIP,int remotePort){
  if (AppNameQueryEngine.isValidQuery(remoteIP,remotePort,localPort) == false)   return null;
  String knownService=AppNameQueryEngine.queryServiceByPort(remotePort);
  if (knownService != null)   return knownService;
  int uid=-1;
  String networkAddr=toString(remoteIP,remotePort,localPort);
  if (connectionCache.contains(networkAddr)) {
    uid=connectionCache.get(networkAddr).uid;
  }
 else {
    debugInfo="String_Node_Str";
    for (int i=0; i < 3; i++) {
      uid=getConnectionUid(localIP,localPort,remoteIP,remotePort);
      Log.d(TAG,"String_Node_Str" + uid);
      if (uid >= 0) {
        break;
      }
 else {
        try {
          Thread.sleep(5);
        }
 catch (        InterruptedException e) {
          e.printStackTrace();
        }
        Log.d(TAG,"String_Node_Str" + i + "String_Node_Str"+ networkAddr+ "String_Node_Str");
        Log.d(TAG,debugInfo);
        Log.d(TAG,"String_Node_Str");
      }
    }
    if (uid < 0)     return null;
    connectionCache.put(networkAddr,new ConnectionCacheItem(uid));
  }
  if (monitorThread == null || monitorThread.isAlive() == false) {
    monitorThread=new Thread(new CacheMonitor());
    monitorThread.start();
  }
  if (uid2PkgName.containsKey(uid) == false) {
    refreshCache(cxt,uid);
  }
  return uid2PkgName.get(uid);
}
Program: 44661
Project: 44661
Buggy source:
/** 
 * get uid info of a connection by looking up proc/net/tcp (tcp6, udp, udp6)
 * @param localIP
 * @param localPort
 * @param remoteIP
 * @param remotePort
 * @return < 0 if not found
 */
public static int getConnectionUid(String localIP,int localPort,String remoteIP,int remotePort){
  String[] ipv4files={"String_Node_Str","String_Node_Str"};
  String[] ipv6files={"String_Node_Str","String_Node_Str"};
  String localAddr=toHexNetworkAddr(localIP,localPort);
  String remoteAddr=toHexNetworkAddr(remoteIP,remotePort);
  int uid=-1;
  for (  String file : ipv4files) {
    if ((uid=getUidFromFile(localAddr,remoteAddr,file)) > 0)     break;
  }
  if (uid < 0) {
    localAddr="String_Node_Str" + localAddr;
    if (remoteAddr.equals("String_Node_Str"))     remoteAddr="String_Node_Str" + remoteAddr;
 else     remoteAddr="String_Node_Str" + remoteAddr;
    for (    String file : ipv6files) {
      if ((uid=getUidFromFile(localAddr,remoteAddr,file)) > 0)       break;
    }
  }
  if (uid < 0) {
    ConnectionCacheItem item=connectionCache.get(toString(remoteIP,remotePort,localPort));
    if (item != null)     uid=item.uid;
  }
  return uid;
}

Fixed version (ground truth):
/** 
 * get uid info of a connection by looking up proc/net/tcp (tcp6, udp, udp6)
 * @param localIP
 * @param localPort
 * @param remoteIP
 * @param remotePort
 * @return < 0 if not found
 */
public static int getConnectionUid(String localIP,int localPort,String remoteIP,int remotePort){
  String[] ipv4files={"String_Node_Str","String_Node_Str"};
  String[] ipv6files={"String_Node_Str","String_Node_Str"};
  String localAddr=toHexNetworkAddr(localIP,localPort);
  String remoteAddr=toHexNetworkAddr(remoteIP,remotePort);
  int uid=-1;
  for (  String file : ipv4files) {
    if ((uid=getUidFromFile(localAddr,remoteAddr,file)) >= 0)     break;
  }
  if (uid < 0) {
    localAddr="String_Node_Str" + localAddr;
    if (remoteAddr.equals("String_Node_Str"))     remoteAddr="String_Node_Str" + remoteAddr;
 else     remoteAddr="String_Node_Str" + remoteAddr;
    for (    String file : ipv6files) {
      if ((uid=getUidFromFile(localAddr,remoteAddr,file)) >= 0)       break;
    }
  }
  if (uid < 0) {
    ConnectionCacheItem item=connectionCache.get(toString(remoteIP,remotePort,localPort));
    if (item != null)     uid=item.uid;
  }
  return uid;
}
Program: 44662
Project: 44662
Buggy source:
public static int getUidFromFile(String localAddr,String remoteAddr,String file){
  ArrayList<String> lines=Utility.readLinesFromFile(file);
  int uid=-1;
  for (  String line : lines) {
    try {
      String[] items=line.split("String_Node_Str");
      if (items[1].equalsIgnoreCase(localAddr) && items[2].equalsIgnoreCase(remoteAddr)) {
        uid=Integer.parseInt(items[7]);
      }
    }
 catch (    Exception e) {
      Log.d(TAG,"String_Node_Str" + e.getMessage());
    }
  }
  return uid;
}

Fixed version (ground truth):
public static int getUidFromFile(String localAddr,String remoteAddr,String file){
  ArrayList<String> lines=Utility.readLinesFromFile(file);
  int uid=-1;
  debugInfo+="String_Node_Str" + localAddr + "String_Node_Str"+ remoteAddr+ "String_Node_Str"+ file+ "String_Node_Str";
  for (  String line : lines) {
    debugInfo+=line + "String_Node_Str";
    try {
      String[] items=line.split("String_Node_Str");
      if (items[1].equalsIgnoreCase(localAddr) && items[2].equalsIgnoreCase(remoteAddr)) {
        debugInfo+="String_Node_Str" + items[7];
        uid=Integer.parseInt(items[7]);
        debugInfo+="String_Node_Str" + uid + "String_Node_Str";
        break;
      }
    }
 catch (    Exception e) {
      Log.d(TAG,"String_Node_Str" + e.getMessage());
    }
  }
  return uid;
}
Program: 44663
Project: 44663
Buggy source:
private void sendOFPacket(Socket socket,byte[] data){
  try {
    OutputStream out=socket.getOutputStream();
    out.write(data);
    out.flush();
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}

Fixed version (ground truth):
private void sendOFPacket(Socket socket,byte[] data){
  try {
    OutputStream out=socket.getOutputStream();
    out.write(data);
    out.flush();
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
catch (  SocketException e) {
    ;
  }
}
Program: 44664
Project: 44664
Buggy source:
private void sendOFPacket(Socket socket,byte[] data){
  try {
    OutputStream out=socket.getOutputStream();
    out.write(data);
    out.flush();
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
catch (  SocketException e) {
    ;
  }
}

Fixed version (ground truth):
private void sendOFPacket(Socket socket,byte[] data){
  try {
    OutputStream out=socket.getOutputStream();
    out.write(data);
    out.flush();
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
}
Program: 44665
Project: 44665
Buggy source:
@Override public void setMac(String mac){
  String[] command={"String_Node_Str","String_Node_Str","String_Node_Str" + getName() + "String_Node_Str"+ mac};
  try {
    Runtime.getRuntime().exec(command).waitFor();
  }
 catch (  Exception e) {
    e.printStackTrace();
  }
  super.setMac(mac);
}

Fixed version (ground truth):
@Override public void setMac(String mac){
  String[] if_down_cmd={"String_Node_Str","String_Node_Str","String_Node_Str" + getName() + "String_Node_Str"};
  String[] set_mac_cmd={"String_Node_Str","String_Node_Str","String_Node_Str" + getName() + "String_Node_Str"+ mac};
  String[] if_up_cmd={"String_Node_Str","String_Node_Str","String_Node_Str" + getName() + "String_Node_Str"};
  try {
    Runtime.getRuntime().exec(if_down_cmd).waitFor();
    Runtime.getRuntime().exec(set_mac_cmd).waitFor();
    Runtime.getRuntime().exec(if_up_cmd).waitFor();
  }
 catch (  Exception e) {
    e.printStackTrace();
  }
  super.setMac(mac);
}
Program: 44666
Project: 44666
Buggy source:
public void doVethInit(){
  NativeCallWrapper.runCommand("String_Node_Str");
  String cmd="String_Node_Str" + HostNetworkState.vethIP + "String_Node_Str"+ HostNetworkState.vethIPMask+ "String_Node_Str";
  NativeCallWrapper.runCommand(cmd);
}

Fixed version (ground truth):
public void doVethInit(){
  NativeCallWrapper.runCommand("String_Node_Str");
  String cmd="String_Node_Str" + HostNetworkConfig.vethIP + "String_Node_Str"+ HostNetworkConfig.vethIPMask+ "String_Node_Str";
  NativeCallWrapper.runCommand(cmd);
}
Program: 44667
Project: 44667
Buggy source:
public void doMobileInit(){
  HostNetworkState.mobileGWIP=System.getProperty("String_Node_Str");
}

Fixed version (ground truth):
public void doMobileInit(){
  HostNetworkConfig.mobileGWIP=System.getProperty("String_Node_Str");
}
Program: 44668
Project: 44668
Buggy source:
public void doWiFiInit(){
  WifiManager wifiMan=(WifiManager)this.getSystemService(Context.WIFI_SERVICE);
  if (wifi_included && !wifiMan.isWifiEnabled()) {
    wifiMan.setWifiEnabled(true);
  }
  WifiInfo wifiInf=wifiMan.getConnectionInfo();
  HostNetworkState.wifiMACaddr=wifiInf.getMacAddress();
  int wifiIP=wifiInf.getIpAddress();
  HostNetworkState.wifiIPaddr=IPv4.fromIPv4Address(wifiIP);
}

Fixed version (ground truth):
public void doWiFiInit(){
  WifiManager wifiMan=(WifiManager)this.getSystemService(Context.WIFI_SERVICE);
  if (wifi_included && !wifiMan.isWifiEnabled()) {
    wifiMan.setWifiEnabled(true);
  }
  WifiInfo wifiInf=wifiMan.getConnectionInfo();
  HostNetworkConfig.wifiMACaddr=wifiInf.getMacAddress();
  int wifiIP=wifiInf.getIpAddress();
  HostNetworkConfig.wifiIPaddr=IPv4.fromIPv4Address(wifiIP);
}
Program: 44669
Project: 44669
Buggy source:
@Override public int hashCode(){
  final int prime=31;
  int result=1;
  result=prime * result + ((clazz == null) ? 0 : clazz.hashCode());
  result=prime * result + ((data == null) ? 0 : data.hashCode());
  return result;
}

Fixed version (ground truth):
@Override public int hashCode(){
  final int prime=31;
  int result=1;
  result=prime * result + ((data == null) ? 0 : data.hashCode());
  return result;
}
Program: 44670
Project: 44670
Buggy source:
@Override public Set<T> intersection(Set<T> set){
  Set<T> intersection=Sets.empty();
  for (  T value : set.sequence()) {
    if (Contains(value)) {
      intersection=intersection.add(value);
    }
  }
  return intersection;
}

Fixed version (ground truth):
@Override public Set<T> intersection(Set<T> set){
  Set<T> intersection=Sets.empty();
  for (  T value : set.sequence()) {
    if (contains(value)) {
      intersection=intersection.add(value);
    }
  }
  return intersection;
}
Program: 44671
Project: 44671
Buggy source:
@Override public boolean equals(Object obj){
  if (this == obj)   return true;
  if (obj == null)   return false;
  if (getClass() != obj.getClass())   return false;
  @SuppressWarnings("String_Node_Str") ImmutableHashSet<T> other=(ImmutableHashSet<T>)obj;
  if (isHashCodeCached() && other.isHashCodeCached() && hashCode() != other.hashCode()) {
    return false;
  }
  int size=0;
  for (  T value : other.sequence()) {
    if (!Contains(value)) {
      return false;
    }
    size++;
  }
  return size() == size;
}

Fixed version (ground truth):
@Override public boolean equals(Object obj){
  if (this == obj)   return true;
  if (obj == null)   return false;
  if (getClass() != obj.getClass())   return false;
  @SuppressWarnings("String_Node_Str") ImmutableHashSet<T> other=(ImmutableHashSet<T>)obj;
  if (isHashCodeCached() && other.isHashCodeCached() && hashCode() != other.hashCode()) {
    return false;
  }
  int size=0;
  for (  T value : other.sequence()) {
    if (!contains(value)) {
      return false;
    }
    size++;
  }
  return size() == size;
}
Program: 44672
Project: 44672
Buggy source:
protected BitmappedNode<T> bitmap(int shift,int hash,T value){
  int shift1=(getHash() >>> shift) & 0x1f;
  int shift2=(hash >>> shift) & 0x1f;
  int tableSize=Math.max(shift1,shift2) + 1;
  List<Node<T>> table=ListUtilites.CreateListWithNullValues(tableSize);
  table.set(shift1,this);
  int bits1=1 << shift1;
  int bits2=1 << shift2;
  if (shift1 == shift2) {
    table.set(shift2,table.get(shift2).add(shift + 5,hash,value));
  }
 else {
    table.set(shift2,new LeafNode<T>(hash,value));
  }
  return new BitmappedNode<T>(shift,bits1 | bits2,table);
}

Fixed version (ground truth):
protected BitmappedNode<T> bitmap(int shift,int hash,T value){
  int shift1=(getHash() >>> shift) & 0x1f;
  int shift2=(hash >>> shift) & 0x1f;
  int tableSize=Math.max(shift1,shift2) + 1;
  List<Node<T>> table=ListUtilites.createListWithNullValues(tableSize);
  table.set(shift1,this);
  int bits1=1 << shift1;
  int bits2=1 << shift2;
  if (shift1 == shift2) {
    table.set(shift2,table.get(shift2).add(shift + 5,hash,value));
  }
 else {
    table.set(shift2,new LeafNode<T>(hash,value));
  }
  return new BitmappedNode<T>(shift,bits1 | bits2,table);
}
Program: 44673
Project: 44673
Buggy source:
private void assertOutsideInterval(Interval<Integer> interval,int value){
  String message=String.format("String_Node_Str",value,interval);
  assertFalse(message,interval.Contains(value));
}

Fixed version (ground truth):
private void assertOutsideInterval(Interval<Integer> interval,int value){
  String message=String.format("String_Node_Str",value,interval);
  assertFalse(message,interval.contains(value));
}
Program: 44674
Project: 44674
Buggy source:
private <T extends Comparable<T>>void assertContains(Interval<T> interval,T value){
  String message=String.format("String_Node_Str",value,interval);
  assertTrue(message,interval.Contains(value));
}

Fixed version (ground truth):
private <T extends Comparable<T>>void assertContains(Interval<T> interval,T value){
  String message=String.format("String_Node_Str",value,interval);
  assertTrue(message,interval.contains(value));
}
Program: 44675
Project: 44675
Buggy source:
@Test public void allOdd() throws Exception {
  assertTrue(oddSequence.toString(),oddSequence.All(Predicates.oddPredicate));
}

Fixed version (ground truth):
@Test public void allOdd() throws Exception {
  assertTrue(oddSequence.toString(),oddSequence.all(Predicates.oddPredicate));
}
Program: 44676
Project: 44676
Buggy source:
@Test public void allReturnsTrueForEmptySequence() throws Exception {
  Sequence<Integer> empty=Sequences.<Integer>empty();
  assertTrue("String_Node_Str",empty.All(Predicates.oddPredicate));
}

Fixed version (ground truth):
@Test public void allReturnsTrueForEmptySequence() throws Exception {
  Sequence<Integer> empty=Sequences.<Integer>empty();
  assertTrue("String_Node_Str",empty.all(Predicates.oddPredicate));
}
Program: 44677
Project: 44677
Buggy source:
@Test public void notAllOdd() throws Exception {
  assertFalse(mixedSequence.toString(),mixedSequence.All(Predicates.oddPredicate));
}

Fixed version (ground truth):
@Test public void notAllOdd() throws Exception {
  assertFalse(mixedSequence.toString(),mixedSequence.all(Predicates.oddPredicate));
}
Program: 44678
Project: 44678
Buggy source:
@Test public void containsNonExistingElementFromCollisionNode() throws Exception {
  Set<TestElement> set=Sets.empty();
  set=set.add(new TestElement(1));
  set=set.add(new TestElement(2));
  assertFalse("String_Node_Str",set.Contains(new TestElement(3)));
}

Fixed version (ground truth):
@Test public void containsNonExistingElementFromCollisionNode() throws Exception {
  Set<TestElement> set=Sets.empty();
  set=set.add(new TestElement(1));
  set=set.add(new TestElement(2));
  assertFalse("String_Node_Str",set.contains(new TestElement(3)));
}
Program: 44679
Project: 44679
Buggy source:
@Test public void addedStringsCanBeFound() throws Exception {
  Set<String> set=Sets.empty();
  int numberOfElements=10000;
  for (int i=0; i < numberOfElements; i++) {
    set=set.add(Integer.toString(i));
  }
  for (int i=0; i < numberOfElements; i++) {
    assertTrue(String.format("String_Node_Str",i),set.Contains(Integer.toString(i)));
  }
}

Fixed version (ground truth):
@Test public void addedStringsCanBeFound() throws Exception {
  Set<String> set=Sets.empty();
  int numberOfElements=10000;
  for (int i=0; i < numberOfElements; i++) {
    set=set.add(Integer.toString(i));
  }
  for (int i=0; i < numberOfElements; i++) {
    assertTrue(String.format("String_Node_Str",i),set.contains(Integer.toString(i)));
  }
}
Program: 44680
Project: 44680
Buggy source:
@Test public void containsNonExistingElementFromLeafNode() throws Exception {
  Set<Integer> set=Sets.empty();
  set=set.add(1);
  assertFalse("String_Node_Str",set.Contains(2));
}

Fixed version (ground truth):
@Test public void containsNonExistingElementFromLeafNode() throws Exception {
  Set<Integer> set=Sets.empty();
  set=set.add(1);
  assertFalse("String_Node_Str",set.contains(2));
}
Program: 44681
Project: 44681
Buggy source:
@Test public void addedIntegersCanBeFound() throws Exception {
  Set<Integer> set=Sets.empty();
  int numberOfElements=10000;
  for (int i=0; i < numberOfElements; i++) {
    set=set.add(i);
  }
  for (int i=0; i < numberOfElements; i++) {
    assertTrue(String.format("String_Node_Str",i),set.Contains(i));
  }
}

Fixed version (ground truth):
@Test public void addedIntegersCanBeFound() throws Exception {
  Set<Integer> set=Sets.empty();
  int numberOfElements=10000;
  for (int i=0; i < numberOfElements; i++) {
    set=set.add(i);
  }
  for (int i=0; i < numberOfElements; i++) {
    assertTrue(String.format("String_Node_Str",i),set.contains(i));
  }
}
Program: 44682
Project: 44682
Buggy source:
@Test public void addingTwoElementsUnequalButWithSameHash() throws Exception {
  Set<TestElement> set=Sets.empty();
  set=set.add(new TestElement(0)).add(new TestElement(1)).add(new TestElement(1)).add(new TestElement(100)).add(new TestElement(101));
  assertEquals("String_Node_Str",4,set.size());
  assertTrue("String_Node_Str",set.Contains(new TestElement(0)));
  assertTrue("String_Node_Str",set.Contains(new TestElement(1)));
  assertTrue("String_Node_Str",set.Contains(new TestElement(100)));
  assertTrue("String_Node_Str",set.Contains(new TestElement(101)));
}

Fixed version (ground truth):
@Test public void addingTwoElementsUnequalButWithSameHash() throws Exception {
  Set<TestElement> set=Sets.empty();
  set=set.add(new TestElement(0)).add(new TestElement(1)).add(new TestElement(1)).add(new TestElement(100)).add(new TestElement(101));
  assertEquals("String_Node_Str",4,set.size());
  assertTrue("String_Node_Str",set.contains(new TestElement(0)));
  assertTrue("String_Node_Str",set.contains(new TestElement(1)));
  assertTrue("String_Node_Str",set.contains(new TestElement(100)));
  assertTrue("String_Node_Str",set.contains(new TestElement(101)));
}
Program: 44683
Project: 44683
Buggy source:
@Test public void containsOnNonExistingElement() throws Exception {
  Set<Integer> set=Sets.empty();
  set=set.add(1).add(2).add(4);
  assertFalse("String_Node_Str",set.Contains(3));
}

Fixed version (ground truth):
@Test public void containsOnNonExistingElement() throws Exception {
  Set<Integer> set=Sets.empty();
  set=set.add(1).add(2).add(4);
  assertFalse("String_Node_Str",set.contains(3));
}
Program: 44684
Project: 44684
Buggy source:
public Sem(int count){
  this.Count=count;
}

Fixed version (ground truth):
public Sem(int count){
  this.Count=count;
  s=new Semaphore(Count);
}
Program: 44685
Project: 44685
Buggy source:
public String getContentType(){
  return contentType;
}

Fixed version (ground truth):
public Optional<String> getContentType(){
  return contentType;
}
Program: 44686
Project: 44686
Buggy source:
public MetaInfo setContentType(String contentType){
  this.contentType=contentType;
  return this;
}

Fixed version (ground truth):
public MetaInfo setContentType(String contentType){
  return setContentType(Optional.of(contentType));
}
Program: 44687
Project: 44687
Buggy source:
static Resource of(int status,String content,String contentType){
  return new Resource(status,content,contentType);
}

Fixed version (ground truth):
static Resource of(int status,byte[] content,Optional<String> contentType){
  return new Resource(status,content,contentType);
}
Program: 44688
Project: 44688
Buggy source:
Resource(int status,String content,String contentType){
  this.status=status;
  this.content=content;
  this.contentType=contentType;
}

Fixed version (ground truth):
Resource(int status,byte[] content,Optional<String> contentType){
  this.status=status;
  this.content=content;
  this.contentType=contentType;
}
Program: 44689
Project: 44689
Buggy source:
public String contentType(){
  return contentType;
}

Fixed version (ground truth):
public Optional<String> contentType(){
  return contentType;
}
Program: 44690
Project: 44690
Buggy source:
public String content(){
  return content;
}

Fixed version (ground truth):
public byte[] content(){
  return content;
}
Program: 44691
Project: 44691
Buggy source:
@Override public void handle(Interest request,Queue response) throws IOException {
  logger.info("String_Node_Str" + request.getName().getName());
  try {
    Optional<Resource> content=WorldWideWeb.get(request.getName().getName());
    if (content.isPresent()) {
      logger.info("String_Node_Str");
      Packets.Data data=new Packets.Data();
      data.getName().setName(request.getName().getName());
      data.getMetadata().setFreshnessPeriod(2);
      data.getMetadata().setContentType(content.get().contentType());
      data.setContent(content.get().content().getBytes());
      response.push(data);
      logger.info("String_Node_Str");
    }
  }
 catch (  SocketException e) {
    logger.error("String_Node_Str",e);
    throw new RuntimeException("String_Node_Str");
  }
catch (  IOException e) {
    logger.error("String_Node_Str",e);
  }
}

Fixed version (ground truth):
@Override public void handle(Interest request,Queue response) throws IOException {
  logger.info("String_Node_Str" + request.getName().getName());
  try {
    Optional<Resource> content=WorldWideWeb.get(request.getName().getName());
    if (content.isPresent()) {
      logger.info("String_Node_Str");
      Packets.Data data=new Packets.Data();
      data.getName().setName(request.getName().getName());
      data.getMetadata().setFreshnessPeriod(2);
      data.getMetadata().setContentType(content.get().contentType());
      data.setContent(content.get().content());
      response.push(data);
      logger.info("String_Node_Str");
    }
  }
 catch (  SocketException e) {
    logger.error("String_Node_Str",e);
    throw new RuntimeException("String_Node_Str");
  }
catch (  IOException e) {
    logger.error("String_Node_Str",e);
  }
}
Program: 44692
Project: 44692
Buggy source:
@Override public void service(ServletRequest req,ServletResponse res) throws ServletException, IOException {
  Packets.Interest interest=new Packets.Interest();
  HttpServletRequest request=(HttpServletRequest)req;
  HttpServletResponse response=(HttpServletResponse)res;
  String url=assemble(request.getRequestURL().toString());
  if (sameHost(url,host,port)) {
    logger.info("String_Node_Str" + url);
    response.sendError(400);
    return;
  }
  interest.getName().setName(url);
  try {
    logger.info("String_Node_Str" + url + "String_Node_Str"+ req.getRemoteAddr());
    Optional<Data> result=client.send(InetSocketAddresses.parse(entrypoint),interest);
    if (result.isPresent()) {
      logger.info("String_Node_Str");
      response.getOutputStream().write(result.get().getContent());
      response.setContentType(result.get().getMetadata().getContentType());
    }
 else {
      logger.info("String_Node_Str");
      response.sendError(404);
    }
  }
 catch (  IllegalArgumentException|IllegalAccessException|InstantiationException e) {
    logger.error(e);
    response.sendError(500);
  }
 finally {
    response.getOutputStream().close();
  }
}

Fixed version (ground truth):
@Override public void service(ServletRequest req,ServletResponse res) throws ServletException, IOException {
  Packets.Interest interest=new Packets.Interest();
  HttpServletRequest request=(HttpServletRequest)req;
  HttpServletResponse response=(HttpServletResponse)res;
  String url=assemble(request.getRequestURL().toString());
  if (sameHost(url,host,port)) {
    logger.info("String_Node_Str" + url);
    response.sendError(400);
    return;
  }
  interest.getName().setName(url);
  try {
    logger.info("String_Node_Str" + url + "String_Node_Str"+ req.getRemoteAddr());
    Optional<Data> result=client.send(InetSocketAddresses.parse(entrypoint),interest);
    if (result.isPresent()) {
      logger.info("String_Node_Str");
      response.getOutputStream().write(result.get().getContent());
      if (result.get().getMetadata().getContentType().isPresent()) {
        response.setContentType(result.get().getMetadata().getContentType().get());
      }
    }
 else {
      logger.info("String_Node_Str");
      response.sendError(404);
    }
  }
 catch (  IllegalArgumentException|IllegalAccessException|InstantiationException e) {
    logger.error(e);
    response.sendError(500);
  }
 finally {
    response.getOutputStream().close();
  }
}
Program: 44693
Project: 44693
Buggy source:
public void testRunnningAll() throws Exception {
  Server www=WorldWideWebServer.server(WorldWideWebServer.defaultServlets());
  www.bind(InetSocketAddresses.parse("String_Node_Str"));
  Gateway.main(new String[]{"String_Node_Str","String_Node_Str"});
  Router.main(new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"});
  Proxy.main(new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"});
  Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),"String_Node_Str");
  assertTrue(content.isPresent());
  assertEquals("String_Node_Str",content.get().content());
}

Fixed version (ground truth):
public void testRunnningAll() throws Exception {
  Server www=WorldWideWebServer.server(WorldWideWebServer.defaultServlets());
  www.bind(InetSocketAddresses.parse("String_Node_Str"));
  Gateway.main(new String[]{"String_Node_Str","String_Node_Str"});
  Router.main(new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"});
  Proxy.main(new String[]{"String_Node_Str","String_Node_Str","String_Node_Str"});
  Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),"String_Node_Str");
  assertTrue(content.isPresent());
  assertEquals("String_Node_Str",new String(content.get().content()));
}
Program: 44694
Project: 44694
Buggy source:
public void testsThatTheContentTypeIsPropagatedThroughTheNetwork() throws Exception {
  Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),"String_Node_Str");
  assertTrue(content.isPresent());
  assertEquals("String_Node_Str",content.get().contentType());
}

Fixed version (ground truth):
public void testsThatTheContentTypeIsPropagatedThroughTheNetwork() throws Exception {
  Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),"String_Node_Str");
  assertTrue(content.isPresent());
  assertEquals("String_Node_Str",content.get().contentType().get());
}
Program: 44695
Project: 44695
Buggy source:
public void test200_direclty() throws IOException {
  Optional<Resource> result=WorldWideWeb.get("String_Node_Str");
  assertTrue(result.isPresent());
  assertEquals("String_Node_Str",result.get().content());
}

Fixed version (ground truth):
public void test200_direclty() throws IOException {
  Optional<Resource> result=WorldWideWeb.get("String_Node_Str");
  assertTrue(result.isPresent());
  assertEquals("String_Node_Str",new String(result.get().content()));
}
Program: 44696
Project: 44696
Buggy source:
public void test200_throughNetwork() throws IOException {
  Optional<Resource> result=WorldWideWeb.get(new InetSocketAddress("String_Node_Str",8080),"String_Node_Str");
  assertTrue(result.isPresent());
  assertEquals("String_Node_Str",result.get().content());
}

Fixed version (ground truth):
public void test200_throughNetwork() throws IOException {
  Optional<Resource> result=WorldWideWeb.get(new InetSocketAddress("String_Node_Str",8080),"String_Node_Str");
  assertTrue(result.isPresent());
  assertEquals("String_Node_Str",new String(result.get().content()));
}
Program: 44697
Project: 44697
Buggy source:
public void testRunnningAll() throws Exception {
  for (int i=0; i < 10; i++) {
    Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),"String_Node_Str");
    assertTrue(content.isPresent());
    assertEquals(1000 * 1000,content.get().content().length());
  }
}

Fixed version (ground truth):
public void testRunnningAll() throws Exception {
  for (int i=0; i < 10; i++) {
    Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),"String_Node_Str");
    assertTrue(content.isPresent());
    assertEquals(1000 * 1000,content.get().content().length);
  }
}
Program: 44698
Project: 44698
Buggy source:
public void testRunnningAll() throws Exception {
  List<String> urls=ImmutableList.of("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  for (  String url : urls) {
    WorldWideWeb.setTimeout(TimeUnit.MINUTES.toMillis(5));
    Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),url);
    assertTrue(content.isPresent());
  }
}

Fixed version (ground truth):
public void testRunnningAll() throws Exception {
  List<String> urls=ImmutableList.of("String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str");
  for (  String url : urls) {
    WorldWideWeb.setTimeout(TimeUnit.MINUTES.toMillis(5));
    Optional<Resource> content=WorldWideWeb.get(InetSocketAddresses.parse("String_Node_Str"),url);
    assertTrue(content.isPresent());
  }
}
Program: 44699
Project: 44699
Buggy source:
@SuppressWarnings("String_Node_Str") public <T>T get(String name){
  Optional<String> value=Optional.absent();
  Object defaultValue=defaultValues.get(name);
  if (line.hasOption(name)) {
    value=Optional.of(line.getOptionValue(name));
  }
  if (defaultValue instanceof Integer) {
    Integer result=value.isPresent() ? Integer.parseInt(value.get()) : (Integer)defaultValue;
    return (T)result;
  }
 else   if (defaultValue instanceof String) {
    String result=value.isPresent() ? value.get() : (String)defaultValue;
    return (T)result;
  }
 else {
    throw new UnsupportedOperationException("String_Node_Str" + name);
  }
}

Fixed version (ground truth):
@Override public String get(){
  Preconditions.checkArgument(argv.length == 2,"String_Node_Str" + arg);
  return argv[1];
}
Program: 44700
Project: 44700
Buggy source:
@Inject public Client(InetSocketAddress host){
  Packets.register();
  this.host=host;
}

Fixed version (ground truth):
@Inject public Client(@Flag("String_Node_Str") String entrypoint){
  Packets.register();
  this.host=InetSocketAddresses.parse(entrypoint);
}
Program: 44701
Project: 44701
Buggy source:
public static void main(String[] args) throws Exception {
  logger.info("String_Node_Str");
  Set<Flag<?>> options=ImmutableSet.of(Flag.of("String_Node_Str","String_Node_Str",true,"String_Node_Str"),Flag.of("String_Node_Str","String_Node_Str",true,8082),Flag.of("String_Node_Str","String_Node_Str",true,"String_Node_Str"));
  Flags flags=Flags.parse(options,args);
  final String host=flags.get("String_Node_Str");
  final int port=flags.get("String_Node_Str");
  final String forwarding=flags.get("String_Node_Str");
  Router router=Guice.createInjector(new Module(InetSocketAddresses.parse(forwarding))).getInstance(Router.class);
  router.bind(new InetSocketAddress(host,port));
}

Fixed version (ground truth):
public static void main(String[] args) throws Exception {
  logger.info("String_Node_Str");
  Router router=Guice.createInjector(new Module(),Flags.asModule(args)).getInstance(Router.class);
  router.bind(new InetSocketAddress(router.host,router.port));
}
Program: 44702
Project: 44702
Buggy source:
@Override protected void configure(){
  ThreadFactory factory=new ThreadFactoryBuilder().setNameFormat("String_Node_Str").build();
  bind(ExecutorService.class).toInstance(Executors.newFixedThreadPool(1,factory));
  bind(InetSocketAddress.class).toInstance(forwardingRouter);
}

Fixed version (ground truth):
@Override protected void configure(){
  ThreadFactory factory=new ThreadFactoryBuilder().setNameFormat("String_Node_Str").build();
  bind(ExecutorService.class).toInstance(Executors.newFixedThreadPool(1,factory));
}
Program: 44703
Project: 44703
Buggy source:
public static void main(String[] args) throws Exception {
  logger.info("String_Node_Str");
  Set<Flag<?>> options=ImmutableSet.of(Flag.of("String_Node_Str","String_Node_Str",true,"String_Node_Str"),Flag.of("String_Node_Str","String_Node_Str",true,8081));
  Flags flags=Flags.parse(options,args);
  final String host=flags.get("String_Node_Str");
  final int port=flags.get("String_Node_Str");
  Gateway router=Guice.createInjector(new Module()).getInstance(Gateway.class);
  router.bind(new InetSocketAddress(host,port));
}

Fixed version (ground truth):
public static void main(String[] args) throws Exception {
  logger.info("String_Node_Str");
  Gateway gateway=Guice.createInjector(new Module(),Flags.asModule(args)).getInstance(Gateway.class);
  gateway.bind(new InetSocketAddress(gateway.host,gateway.port));
}