Mercurial > projects > dwt-addons
comparison dwtx/draw2d/IFigure.d @ 105:2be5f40557e6
Fix segfault on attemp to synchronize on interface classinfo
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Thu, 07 Aug 2008 16:03:20 +0200 |
parents | 2d6540440fe6 |
children |
comparison
equal
deleted
inserted
replaced
104:04b47443bb01 | 105:2be5f40557e6 |
---|---|
58 } | 58 } |
59 } | 59 } |
60 | 60 |
61 private static bool initStaticCtor_done = false; | 61 private static bool initStaticCtor_done = false; |
62 private static void initStaticCtor (){ | 62 private static void initStaticCtor (){ |
63 synchronized( IFigure.classinfo ){ | 63 // synchronizing on IFigure gave a segmentation fault |
64 synchronized( Object.classinfo ){ | |
64 if( !initStaticCtor_done ){ | 65 if( !initStaticCtor_done ){ |
65 IFigure_MAX_DIMENSION_ = new Dimension(Integer.MAX_VALUE, Integer.MAX_VALUE); | 66 IFigure_MAX_DIMENSION_ = new Dimension(Integer.MAX_VALUE, Integer.MAX_VALUE); |
66 IFigure_MIN_DIMENSION_ = new Dimension(5, 5); | 67 IFigure_MIN_DIMENSION_ = new Dimension(5, 5); |
67 IFigure_NO_INSETS_ = new NoInsets(); | 68 IFigure_NO_INSETS_ = new NoInsets(); |
68 initStaticCtor_done = true; | 69 initStaticCtor_done = true; |