You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While the spec only includes commitment_signed messages in batches,
there may be other types of batches in the future. Generalize the
message batching code to allow for other types in the future.
log_debug!(logger,"Peer {} sent batched commitment_signed for the wrong channel (expected: {}, actual: {})", log_pubkey!(their_node_id), channel_id,&msg.channel_id);
log_debug!(logger,"Peer {} sent batched commitment_signed for the wrong channel (expected: {}, actual: {})", log_pubkey!(their_node_id), message_batch.channel_id,&msg.channel_id);
1800
1836
returnErr(PeerHandleError{}.into());
1801
1837
}
1802
1838
1803
1839
let funding_txid = match msg.funding_txid{
1804
1840
Some(funding_txid) => funding_txid,
1805
1841
None => {
1806
-
log_debug!(logger,"Peer {} sent batched commitment_signed without a funding_txid for channel {}", log_pubkey!(their_node_id), channel_id);
1842
+
log_debug!(logger,"Peer {} sent batched commitment_signed without a funding_txid for channel {}", log_pubkey!(their_node_id),message_batch.channel_id);
log_debug!(logger,"Peer {} sent batched commitment_signed with duplicate funding_txid {} for channel {}", log_pubkey!(their_node_id), funding_txid, channel_id);
1850
+
log_debug!(logger,"Peer {} sent batched commitment_signed with duplicate funding_txid {} for channel {}", log_pubkey!(their_node_id), funding_txid,message_batch.channel_id);
1815
1851
returnErr(PeerHandleError{}.into());
1816
1852
}
1817
1853
}
1818
1854
1819
-
if buffer.len() == *batch_size {
1820
-
let(channel_id, _, batch) = peer_lock.commitment_signed_batch.take().expect("batch should have been inserted");
1855
+
if buffer.len() == message_batch.batch_size{
1856
+
letMessageBatch{ channel_id,batch_size: _, messages } = peer_lock.message_batch.take().expect("batch should have been inserted");
0 commit comments