Skip to content

Commit

Permalink
fixed regressions
Browse files Browse the repository at this point in the history
  • Loading branch information
maniksurtani committed Oct 21, 2010
1 parent 661b0cf commit a43531e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
Expand All @@ -32,8 +33,8 @@ public class RemoteTransaction implements CacheTransaction, Cloneable {


public RemoteTransaction(WriteCommand[] modifications, GlobalTransaction tx) {
this.modifications = Arrays.asList(modifications);
lookedUpEntries = new BidirectionalLinkedHashMap<Object, CacheEntry>(modifications.length);
this.modifications = modifications == null || modifications.length == 0 ? Collections.<WriteCommand>emptyList(): Arrays.asList(modifications);
lookedUpEntries = new BidirectionalLinkedHashMap<Object, CacheEntry>(this.modifications.size());
this.tx = tx;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public void testExplicitLockingRemoteTimeout() throws NotSupportedException, Sys
tm.rollback();
assertEquals(0, txTable0.getLocalTxCount());
assertEquals(1, txTable1.getLocalTxCount());
assertEquals(0, txTable1.getRemoteTxCount());
assertEquals(1, txTable1.getRemoteTxCount());


tm.resume(k1LockOwner);
Expand Down

0 comments on commit a43531e

Please sign in to comment.