[Libreoffice-commits] core.git: Branch 'aoo/trunk' - jvmfwk/plugins

Damjan Jovanovic damjan at apache.org
Sun Apr 15 16:10:24 UTC 2018


 jvmfwk/plugins/sunmajor/pluginlib/sunversion.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 5d4ce3e29c7aab3498e0955485d8707a8f5fb456
Author: Damjan Jovanovic <damjan at apache.org>
Date:   Sun Apr 15 15:00:46 2018 +0000

    Allow the Java version suffix (eg. the 162 in 1.8.0_162) to be
    
    3 digits long.
    
    Patch by: me

diff --git a/jvmfwk/plugins/sunmajor/pluginlib/sunversion.cxx b/jvmfwk/plugins/sunmajor/pluginlib/sunversion.cxx
index a9c98ddae024..c1872f0d61f4 100644
--- a/jvmfwk/plugins/sunmajor/pluginlib/sunversion.cxx
+++ b/jvmfwk/plugins/sunmajor/pluginlib/sunversion.cxx
@@ -144,8 +144,9 @@ bool SunVersion::init(const char *szVersion)
                 if ( ! isdigit(*pCur))
                 {
                     //1.4.1_01-, 1.4.1_01a, the numerical part may only be 2 chars.
+                    //1.7.0_161, 1.8.0_162, it's as long as 3 chars in later Java version.
                     int len = pCur - pLast;
-                    if (len > 2)
+                    if (len > 3)
                         return false;
                     //we've got the update: 01, 02 etc
                     strncpy(buf, pLast, len);


More information about the Libreoffice-commits mailing list