Hi Piotr,

I see in the release notes that the fix made it in 2.19.0 RC1, thank you!

Gary

On Thu, Jul 21, 2022, 17:33 Gary Gregory <garydgreg...@gmail.com> wrote:

> Hi Piotr,
>
> Thank you so much for the quick analysis!
>
> Gary
>
>
> On Thu, Jul 21, 2022, 17:35 Piotr P. Karwasz <piotr.karw...@gmail.com>
> wrote:
>
>> Hi Gary,
>>
>> > The script that starts our app uses an environment variable called
>> > LOG4J and starting with 2.18.0, Log4j puts the content of this
>> > environment variable in ALL system properties.
>> >
>> > Thoughts?
>>
>> Sorry, I must have broken it while fixing LOG4J-3413. The
>> ConsoleAppender is actually calling
>> PropertiesUtil.getCharsetProperty("sun.stdout.encoding") and:
>>
>> * it looks up a literal environment/system property
>> "sun.stdout.encoding" and finds nothing,
>> * it tokenizes "sun.stdout.encoding" and obtains an empty list of
>> tokens (this should prevent "configurationFile" to be confused with
>> "log4j2.configurationFile"),
>> * it normalizes the empty list of tokens and looks up a Java system
>> property named "log4j2" and an environment variable named "LOG4J".
>>
>> I'll fix it tomorrow and add a test.
>>
>> Piotr
>>
>

Reply via email to