File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed
crates/mpc-tls/src/record_layer/aead Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -287,9 +287,12 @@ struct TagShare([u8; 16]);
287287impl Add for TagShare {
288288 type Output = Vec < u8 > ;
289289
290- fn add ( mut self , rhs : Self ) -> Self :: Output {
291- self . 0 . iter_mut ( ) . zip ( rhs. 0 ) . for_each ( |( a, b) | * a ^= b) ;
292- self . 0 . to_vec ( )
290+ fn add ( self , rhs : Self ) -> Self :: Output {
291+ self . 0
292+ . iter ( )
293+ . zip ( rhs. 0 )
294+ . map ( |( a, b) | * a ^ b)
295+ . collect :: < Vec < _ > > ( )
293296 }
294297}
295298
Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ impl Task for ComputeTags {
9595 let tags = tag_shares
9696 . into_iter ( )
9797 . zip ( follower_tag_shares)
98- . map ( |( a, b) | ( a + b) . to_vec ( ) )
98+ . map ( |( a, b) | a + b)
9999 . collect ( ) ;
100100
101101 Some ( tags)
You can’t perform that action at this time.
0 commit comments