mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-15 20:29:52 +01:00
Unit tests and a bugfix. THE SYSTEM WORKS!
This commit is contained in:
@@ -357,7 +357,7 @@ class ReadWriteLockDatabaseComponent<Txn> extends DatabaseComponentImpl<Txn> {
|
||||
int bytesSent = 0;
|
||||
for(MessageId m : requested) {
|
||||
byte[] message = db.getMessageIfSendable(txn, c, m);
|
||||
if(b == null) continue; // Expired or not sendable
|
||||
if(message == null) continue;
|
||||
if(!b.writeMessage(message)) break;
|
||||
bytesSent += message.length;
|
||||
sent.add(m);
|
||||
|
||||
@@ -260,7 +260,7 @@ class SynchronizedDatabaseComponent<Txn> extends DatabaseComponentImpl<Txn> {
|
||||
int bytesSent = 0;
|
||||
for(MessageId m : requested) {
|
||||
byte[] message = db.getMessageIfSendable(txn, c, m);
|
||||
if(b == null) continue; // Expired or not sendable
|
||||
if(message == null) continue;
|
||||
if(!b.writeMessage(message)) break;
|
||||
bytesSent += message.length;
|
||||
sent.add(m);
|
||||
|
||||
Reference in New Issue
Block a user