tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Konstantin Kolinko <knst.koli...@gmail.com>
Subject Re: svn commit: r1099394 - in /tomcat/trunk: res/tomcat.nsi webapps/docs/changelog.xml
Date Wed, 04 May 2011 10:30:26 GMT
2011/5/4  <markt@apache.org>:
> Author: markt
> Date: Wed May  4 10:14:19 2011
> New Revision: 1099394
>
> URL: http://svn.apache.org/viewvc?rev=1099394&view=rev
> Log:
> Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=51135
> Fix auto-detection of JAVA_HOME for 64-bit Windows platforms that only have a 32-bit
JVM installed.
>
> Modified:
>    tomcat/trunk/res/tomcat.nsi
>    tomcat/trunk/webapps/docs/changelog.xml
>
> Modified: tomcat/trunk/res/tomcat.nsi
> URL: http://svn.apache.org/viewvc/tomcat/trunk/res/tomcat.nsi?rev=1099394&r1=1099393&r2=1099394&view=diff
> ==============================================================================
> --- tomcat/trunk/res/tomcat.nsi (original)
> +++ tomcat/trunk/res/tomcat.nsi Wed May  4 10:14:19 2011
> @@ -635,22 +635,35 @@ Function findJavaHome
>
>   ClearErrors

StrCpy $1 ""

Add the above line here as well, to initialize $1 when running with
32-bit. That is because you are checking ${If} $1 == "" below, but the
initial value of $1 is not known.

>
> -  ; Use the 64-bit registry on 64-bit machines
> +  ; Use the 64-bit registry first on 64-bit machines
>   ExpandEnvStrings $0 "%PROGRAMW6432%"
>   ${If} $0 != "%PROGRAMW6432%"
>     SetRegView 64
> +    ReadRegStr $2 HKLM "SOFTWARE\JavaSoft\Java Runtime Environment" "CurrentVersion"
> +    ReadRegStr $1 HKLM "SOFTWARE\JavaSoft\Java Runtime Environment\$2" "JavaHome"
> +    ReadRegStr $3 HKLM "SOFTWARE\JavaSoft\Java Runtime Environment\$2" "RuntimeLib"
> +
> +    IfErrors 0 +2
> +    StrCpy $1 ""
> +    ClearErrors
>   ${EndIf}
(...)

Best regards,
Konstantin Kolinko

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message