mirror of
https://github.com/vlang/v.git
synced 2025-09-16 16:02:29 +03:00
fmt: fix alignment of struct init fields (#22025)
This commit is contained in:
parent
99da5726db
commit
c51d30bf53
671 changed files with 18817 additions and 18787 deletions
|
@ -35,10 +35,10 @@ pub fn (mut x Cbc) free() {
|
|||
// internal
|
||||
fn new_des_cbc(b Block, iv []u8) Cbc {
|
||||
return Cbc{
|
||||
b: b
|
||||
b: b
|
||||
block_size: b.block_size
|
||||
iv: iv.clone()
|
||||
tmp: []u8{len: b.block_size}
|
||||
iv: iv.clone()
|
||||
tmp: []u8{len: b.block_size}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -53,11 +53,11 @@ fn new_cfb(b Block, iv []u8, decrypt bool) Cfb {
|
|||
panic('cipher.new_cfb: IV length must be equal block size')
|
||||
}
|
||||
mut x := Cfb{
|
||||
b: b
|
||||
out: []u8{len: b.block_size}
|
||||
next: []u8{len: b.block_size}
|
||||
b: b
|
||||
out: []u8{len: b.block_size}
|
||||
next: []u8{len: b.block_size}
|
||||
out_used: block_size
|
||||
decrypt: decrypt
|
||||
decrypt: decrypt
|
||||
}
|
||||
copy(mut x.next, iv)
|
||||
return x
|
||||
|
|
|
@ -42,9 +42,9 @@ pub fn new_ctr(b Block, iv []u8) Ctr {
|
|||
panic('cipher.new_cfb: IV length must be equal block size')
|
||||
}
|
||||
return Ctr{
|
||||
b: b
|
||||
out: []u8{len: b.block_size}
|
||||
next: iv.clone()
|
||||
b: b
|
||||
out: []u8{len: b.block_size}
|
||||
next: iv.clone()
|
||||
out_used: block_size
|
||||
}
|
||||
}
|
||||
|
|
|
@ -26,9 +26,9 @@ pub fn new_ofb(b Block, iv []u8) Ofb {
|
|||
panic('cipher.new_ofb: IV length must be equal block size')
|
||||
}
|
||||
mut x := Ofb{
|
||||
b: b
|
||||
out: []u8{len: b.block_size}
|
||||
next: []u8{len: b.block_size}
|
||||
b: b
|
||||
out: []u8{len: b.block_size}
|
||||
next: []u8{len: b.block_size}
|
||||
out_used: block_size
|
||||
}
|
||||
copy(mut x.next, iv)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue