Program: 96359
Project: 96359
Buggy source:
/** 
 * @param trayType LINUX_GTK = 1; LINUX_APP_INDICATOR = 2; SWING_INDICATOR = 3;
 */
public static void determineIconSize(int trayType){
  if (SystemTray.AUTO_TRAY_SIZE) {
    if (OS.isWindows()) {
      SIZE=SystemTray.DEFAULT_WINDOWS_SIZE;
    }
 else {
      if (trayType == SystemTray.TYPE_SWING || trayType == SystemTray.TYPE_GTK_STATUSICON) {
        SIZE=SystemTray.DEFAULT_LINUX_SIZE;
      }
 else {
        int uiScalingFactor=0;
        try {
          ByteArrayOutputStream byteArrayOutputStream=new ByteArrayOutputStream(8196);
          PrintStream outputStream=new PrintStream(byteArrayOutputStream);
          final ShellProcessBuilder shellVersion=new ShellProcessBuilder(outputStream);
          shellVersion.setExecutable("String_Node_Str");
          shellVersion.addArgument("String_Node_Str");
          shellVersion.addArgument("String_Node_Str");
          shellVersion.addArgument("String_Node_Str");
          shellVersion.start();
          String output=ShellProcessBuilder.getOutput(byteArrayOutputStream);
          if (!output.isEmpty()) {
            if (SystemTray.DEBUG) {
              SystemTray.logger.info("String_Node_Str",output);
            }
            if (output.startsWith("String_Node_Str")) {
              String value=output.substring(output.indexOf("String_Node_Str") + 1,output.length() - 1);
              uiScalingFactor=Integer.parseInt(value);
            }
          }
        }
 catch (        Throwable e) {
          if (SystemTray.DEBUG) {
            SystemTray.logger.error("String_Node_Str",e);
          }
        }
        if (uiScalingFactor > 1) {
          SIZE=SystemTray.DEFAULT_LINUX_SIZE * uiScalingFactor;
        }
 else {
          SIZE=SystemTray.DEFAULT_LINUX_SIZE;
        }
        if (SystemTray.DEBUG) {
          SystemTray.logger.info("String_Node_Str",uiScalingFactor,SIZE);
        }
      }
    }
  }
 else {
    if (OS.isWindows()) {
      SIZE=SystemTray.DEFAULT_WINDOWS_SIZE;
    }
 else {
      SIZE=SystemTray.DEFAULT_LINUX_SIZE;
    }
  }
}

Fixed version (ground truth):
/** 
 * @param trayType LINUX_GTK = 1; LINUX_APP_INDICATOR = 2; SWING_INDICATOR = 3;
 */
public static void determineIconSize(int trayType){
  int trayScale=0;
  int menuScale=0;
  if (SystemTray.AUTO_TRAY_SIZE) {
    if (OS.isWindows()) {
      trayScale=SystemTray.DEFAULT_WINDOWS_SIZE;
      menuScale=SystemTray.DEFAULT_MENU_SIZE;
    }
 else {
      if (trayType == SystemTray.TYPE_SWING || trayType == SystemTray.TYPE_GTK_STATUSICON) {
        trayScale=SystemTray.DEFAULT_LINUX_SIZE;
        menuScale=SystemTray.DEFAULT_MENU_SIZE;
      }
 else {
        int uiScalingFactor=0;
        try {
          ByteArrayOutputStream byteArrayOutputStream=new ByteArrayOutputStream(8196);
          PrintStream outputStream=new PrintStream(byteArrayOutputStream);
          final ShellProcessBuilder shellVersion=new ShellProcessBuilder(outputStream);
          shellVersion.setExecutable("String_Node_Str");
          shellVersion.addArgument("String_Node_Str");
          shellVersion.addArgument("String_Node_Str");
          shellVersion.addArgument("String_Node_Str");
          shellVersion.start();
          String output=ShellProcessBuilder.getOutput(byteArrayOutputStream);
          if (!output.isEmpty()) {
            if (SystemTray.DEBUG) {
              SystemTray.logger.debug("String_Node_Str",output);
            }
            if (output.contains("String_Node_Str")) {
              String value=output.substring(output.indexOf("String_Node_Str") + 7,output.length() - 1);
              uiScalingFactor=Integer.parseInt(value);
            }
          }
        }
 catch (        Throwable e) {
          if (SystemTray.DEBUG) {
            SystemTray.logger.error("String_Node_Str",e);
          }
        }
        if (uiScalingFactor > 1) {
          trayScale=SystemTray.DEFAULT_LINUX_SIZE * uiScalingFactor;
          menuScale=SystemTray.DEFAULT_MENU_SIZE * uiScalingFactor;
        }
 else {
          trayScale=SystemTray.DEFAULT_LINUX_SIZE;
          menuScale=SystemTray.DEFAULT_MENU_SIZE;
        }
        if (SystemTray.DEBUG) {
          SystemTray.logger.debug("String_Node_Str",uiScalingFactor,trayScale);
        }
      }
    }
  }
 else {
    if (OS.isWindows()) {
      trayScale=SystemTray.DEFAULT_WINDOWS_SIZE;
      menuScale=SystemTray.DEFAULT_MENU_SIZE;
    }
 else {
      trayScale=SystemTray.DEFAULT_LINUX_SIZE;
      menuScale=SystemTray.DEFAULT_MENU_SIZE;
    }
  }
  TRAY_SIZE=trayScale;
  ENTRY_SIZE=menuScale;
}