[Libreoffice-commits] core.git: cui/source

Stephan Bergmann sbergman at redhat.com
Tue Apr 11 15:53:17 UTC 2017


 cui/source/options/optjava.cxx |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 6bb4c48812224237c29acf31264cc05e2938f242
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Tue Apr 11 17:52:50 2017 +0200

    Determine accurate position for already added JREs
    
    Change-Id: Ieef6aaeccd3368fa1cf79b3eab510b6b6c24427e

diff --git a/cui/source/options/optjava.cxx b/cui/source/options/optjava.cxx
index 20fd7a9e0f5c..bef9f2543ec3 100644
--- a/cui/source/options/optjava.cxx
+++ b/cui/source/options/optjava.cxx
@@ -586,9 +586,9 @@ void SvxJavaOptionsPage::AddFolder( const OUString& _rFolder )
             if ( jfw_areEqualJavaInfo( pCmpInfo, pInfo ) )
             {
                 bFound = true;
-                nPos = i;
                 break;
             }
+            ++nPos;
         }
 
         if ( !bFound )
@@ -602,6 +602,7 @@ void SvxJavaOptionsPage::AddFolder( const OUString& _rFolder )
                     bFound = true;
                     break;
                 }
+                ++nPos;
             }
         }
 


More information about the Libreoffice-commits mailing list