diff options
author | Eric Botcazou <ebotcazou@libertysurf.fr> | 2005-01-05 06:09:09 +0100 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2005-01-05 05:09:09 +0000 |
commit | ec24eb4ebbdb24aa5b67cd6789d88946bb296f24 (patch) | |
tree | 90f10e8b66126b935b49e0bb9f38a63cd100fc20 /libjava | |
parent | e82f57499b484397843383bfcb8a2aac7deebcf0 (diff) | |
download | gcc-ec24eb4ebbdb24aa5b67cd6789d88946bb296f24.zip gcc-ec24eb4ebbdb24aa5b67cd6789d88946bb296f24.tar.gz gcc-ec24eb4ebbdb24aa5b67cd6789d88946bb296f24.tar.bz2 |
natObject.cc (_Jv_ObjectCheckMonitor): Initialize the sync_info element of the object if needed.
* java/lang/natObject.cc (_Jv_ObjectCheckMonitor): Initialize the
sync_info element of the object if needed.
From-SVN: r92922
Diffstat (limited to 'libjava')
-rw-r--r-- | libjava/ChangeLog | 5 | ||||
-rw-r--r-- | libjava/java/lang/natObject.cc | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 6db73b1..90d2fe4 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,8 @@ +2005-01-05 Eric Botcazou <ebotcazou@libertysurf.fr> + + * java/lang/natObject.cc (_Jv_ObjectCheckMonitor): Initialize the + sync_info element of the object if needed. + 2005-01-03 Eric Botcazou <ebotcazou@libertysurf.fr> * testsuite/libjava.lang/Process_4.java (Process_4): Expect only diff --git a/libjava/java/lang/natObject.cc b/libjava/java/lang/natObject.cc index 7dff626..d7b67d7 100644 --- a/libjava/java/lang/natObject.cc +++ b/libjava/java/lang/natObject.cc @@ -267,6 +267,8 @@ _Jv_MonitorExit (jobject obj) bool _Jv_ObjectCheckMonitor (jobject obj) { + if (__builtin_expect (INIT_NEEDED (obj), false)) + obj->sync_init (); _Jv_SyncInfo *si = (_Jv_SyncInfo *) obj->sync_info; return _Jv_MutexCheckMonitor (&si->mutex); } |