< prev index next >

src/java.base/share/native/libjava/System.c

Print this page
rev 49281 : 8199756: Simplify language, country, script, and variant property initialization

*** 242,266 **** PUTPROP(props, "file.separator", sprops->file_separator); PUTPROP(props, "path.separator", sprops->path_separator); PUTPROP(props, "line.separator", sprops->line_separator); /* ! * user.language ! * user.script, user.country, user.variant (if user's environment specifies them) ! * file.encoding */ - PUTPROP(props, "user.language", sprops->language); - if (sprops->script) { - PUTPROP(props, "user.script", sprops->script); - } - if (sprops->country) { - PUTPROP(props, "user.country", sprops->country); - } - if (sprops->variant) { - PUTPROP(props, "user.variant", sprops->variant); - } - PUTPROP(props, "file.encoding", sprops->encoding); if (sprops->sun_stdout_encoding != NULL) { PUTPROP(props, "sun.stdout.encoding", sprops->sun_stdout_encoding); } if (sprops->sun_stderr_encoding != NULL) { PUTPROP(props, "sun.stderr.encoding", sprops->sun_stderr_encoding); --- 242,253 ---- PUTPROP(props, "file.separator", sprops->file_separator); PUTPROP(props, "path.separator", sprops->path_separator); PUTPROP(props, "line.separator", sprops->line_separator); /* ! * file encoding for stdout and stderr */ if (sprops->sun_stdout_encoding != NULL) { PUTPROP(props, "sun.stdout.encoding", sprops->sun_stdout_encoding); } if (sprops->sun_stderr_encoding != NULL) { PUTPROP(props, "sun.stderr.encoding", sprops->sun_stderr_encoding);
*** 312,322 **** PUTPROP(props, "socksNonProxyHosts", sprops->exceptionList); } #endif /* !!! DO NOT call PUTPROP_ForPlatformNString before this line !!! ! * !!! I18n properties have not been set up yet !!! */ InitializeEncoding(env, sprops->sun_jnu_encoding); /* Printing properties */ /* Note: java.awt.printerjob is an implementation private property which --- 299,309 ---- PUTPROP(props, "socksNonProxyHosts", sprops->exceptionList); } #endif /* !!! DO NOT call PUTPROP_ForPlatformNString before this line !!! ! * !!! The platform native encoding for strings has not been set up yet !!! */ InitializeEncoding(env, sprops->sun_jnu_encoding); /* Printing properties */ /* Note: java.awt.printerjob is an implementation private property which
*** 377,397 **** */ if (sprops->desktop != NULL) { PUTPROP(props, "sun.desktop", sprops->desktop); } - /* - * unset "user.language", "user.script", "user.country", and "user.variant" - * in order to tell whether the command line option "-DXXXX=YYYY" is - * specified or not. They will be reset in fillI18nProps() below. - */ - REMOVEPROP(props, "user.language"); - REMOVEPROP(props, "user.script"); - REMOVEPROP(props, "user.country"); - REMOVEPROP(props, "user.variant"); - REMOVEPROP(props, "file.encoding"); - ret = JVM_InitProperties(env, props); /* reconstruct i18n related properties */ fillI18nProps(env, props, "user.language", sprops->display_language, sprops->format_language, putID, getPropID); --- 364,373 ----
< prev index next >