This is the mail archive of the java-discuss@sources.redhat.com mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

_Jv_MonitorEnter interface confusion?


I'm trying to integrate hash synchronization code into my tree:

As far as I can tell _Jv_MonitorEnter and _Jv_MonitorExit are both declared
to return an error code, but _Jv_MonitorExit in fact throws an exception in
the most likely error case.

_Jv_MonitorEnter returns the result returned by _Jv_MutexLock, which can
return a nonzero code only under Windows.

I don't think any of the callers actually test the result returned by
_Jv_MonitorEnter and _Jv_MonitorExit.

This seems wrong.  Should _Jv_MonitorEnter and _Jv_MonitorExit return void
and throw if necessary?  Am I overlooking something?

Hans


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]