<AWT Dev> numAppContexts in AppContext modified in not-thread-safe way.

Mario Torre neugens.limasoftware at gmail.com
Thu Aug 18 11:40:26 PDT 2011

2011/8/18 Clemens Eisserer <linuxhippy at gmail.com>:
> Sorry the first patch was broken, as the static block executed before the
> static initializer.
> I've uploaded a corrected version to:
> http://cr.openjdk.java.net/~ceisserer/7080700/webrev.01/
> Is it ok to initialize to 1 directly in line 199?
> Thanks Clemens

It looks good to me, and I don't expect any issues after this patch.
The only thing is that you should check the settings for the editor, I
think you still use a mix of tabs and spaces :)


public final static AppContext getAppContext()

Doesn't seem to be thread safe by nature, I don't know if this is part
of the issue you found, so maybe you should consider to synchronize
this as well.

pgp key: http://subkeys.pgp.net/ PGP Key ID: 80F240CF
Fingerprint: BA39 9666 94EC 8B73 27FA  FC7C 4086 63E3 80F2 40CF

IcedRobot: www.icedrobot.org
Proud GNU Classpath developer: http://www.classpath.org/
Read About us at: http://planet.classpath.org
OpenJDK: http://openjdk.java.net/projects/caciocavallo/

Please, support open standards:

More information about the awt-dev mailing list