6891483: XToolkit.getEnv() checks for NULL on a wrong symbol

Reviewed-by: dcherepanov
This commit is contained in:
Anthony Petrov 2009-10-19 16:06:41 +04:00
parent 720170db8b
commit a77b6a72e0

View File

@ -677,7 +677,7 @@ JNIEXPORT jstring JNICALL Java_sun_awt_X11_XToolkit_getEnv
jstring ret = NULL;
keystr = JNU_GetStringPlatformChars(env, key, NULL);
if (key) {
if (keystr) {
ptr = getenv(keystr);
if (ptr) {
ret = JNU_NewStringPlatform(env, (const char *) ptr);