Was a little overeager with my previous patch. The other one would not recognize a 32bit Java on a 64bit Windows.
added additional "IfErrors 0 JreFound" after 32bit Registry search to goto sucess case if JRE was found.
This version will choose 32bit over 64bit if both are installed.
Patch for previous patched launcher.nsi
Thank you for this patch! Have I understood it correctly, that the effect of this patch is to ensure that a 64 bit JRE is detected, while preferring a 32 bit JRE if both are installed?
The latter effect may be very useful for the OpenOffice/LibreOffice functionality, since these come only in 32 bit versions, and we can only connect while running on a 32 bit JVM.
Yes, it checks the in this order
1 - in .\jre directory (JRE Installed with application)
2 - in JAVA_HOME environment variable
3 - in the (32bit) registry
4 - in the 64bit registry for 64bit JavaRE
And uses the first one it can find.