From ca200934721883ff5e86067291fbbc42ca159ef8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Richard=20K=C3=B6rber?= Date: Sat, 18 Apr 2020 19:16:05 +0200 Subject: [PATCH] Remove Java version evaluation According to JEP223, Java versions do not include trailing zero elements. This means that e.g. Java 14.0.0 reports its version just as "14". The changed code part expected at least three characters, so it failed to start on such "zero-zero" Java releases. The evaluated java version was not used anywhere, so the code block was removed. --- .../src/processing/app/legacy/PApplet.java | 21 ------------------- 1 file changed, 21 deletions(-) diff --git a/arduino-core/src/processing/app/legacy/PApplet.java b/arduino-core/src/processing/app/legacy/PApplet.java index d9eea95fd..4a803ef16 100644 --- a/arduino-core/src/processing/app/legacy/PApplet.java +++ b/arduino-core/src/processing/app/legacy/PApplet.java @@ -16,27 +16,6 @@ public class PApplet { /** Path to sketch folder */ public String sketchPath; //folder; - /** - * Full name of the Java version (i.e. 1.5.0_11). - * Prior to 0125, this was only the first three digits. - */ - public static final String javaVersionName = - System.getProperty("java.version"); - - /** - * Version of Java that's in use, whether 1.1 or 1.3 or whatever, - * stored as a float. - *

- * Note that because this is stored as a float, the values may - * not be exactly 1.3 or 1.4. Instead, make sure you're - * comparing against 1.3f or 1.4f, which will have the same amount - * of error (i.e. 1.40000001). This could just be a double, but - * since Processing only uses floats, it's safer for this to be a float - * because there's no good way to specify a double with the preproc. - */ - public static final float javaVersion = - new Float(javaVersionName.substring(0, 3)).floatValue(); - /** * Current platform in use, one of the * PConstants WINDOWS, MACOSX, MACOS9, LINUX or OTHER.