db-ojb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gerhard.Gro...@lex-com.net
Subject Problem with odmg.TransactionImpl
Date Thu, 02 Oct 2003 12:39:01 GMT
I encountered a problem with class org.apache.ojb.odmg.TransactionImpl: If 
a transaction is opened and committed without ever any object being 
locked, a NullPointerException is thrown at line 323 (method 
doCommitOnObjects): 

        if(!broker.isInTransaction()) broker.beginTransaction();

I believe the fix would be to use the getBroker() method instead of 
referring to the instance variable directly:

        if(!getBroker().isInTransaction()) broker.beginTransaction();

Could somebody confirm this?

Gerhard
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message