Atomikos Forum

NPE in AtomikosThreadLocalConnection

AtomikosThreadLocalConnection.java

CT can be NULL!
Right code :



            if ( !isInTransaction ( ct ) )
                throw new AtomikosSQLException (
                        "Connection accessed by transaction "
                                + (ct==null ? "null" : ct.getTid ()) ///CK
                                + " is already in use in another transaction: "
                                + transaction.getTid ()
                                + " Non-XA connections are not compatible with nested transaction use." );
cesnek Send private email
Wednesday, September 24, 2008
 
 
Hi,

Thanks for the feedback.

Actually, if ct == null then the check for isInTransaction(ct) returns false, and the block won't be executed.

Cheers
Guy Pardon Send private email
Friday, September 26, 2008
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics