History

bpf: Remove insn_buf[] declaration in inner block

Two insn_buf[16] variables are declared in the function which acts on function scope and block scope respectively. The statement in the inner block is redundant, so remove it.

Jianlin Lv committed 5 years ago

Commit 9ef05281 parent ea24b191 file · +0 −1Browse files

Unified · Split

kernel/bpf/verifier.c+0−1
@@ -11899,7 +11899,6 @@ static int do_misc_fixups(struct bpf_verifier_env *env) · 11898 unmodified lines
1189911899 insn->code == (BPF_ALU64 | BPF_SUB | BPF_X)) {
1190011900 const u8 code_add = BPF_ALU64 | BPF_ADD | BPF_X;
1190111901 const u8 code_sub = BPF_ALU64 | BPF_SUB | BPF_X;
11902− struct bpf_insn insn_buf[16];
1190311902 struct bpf_insn *patch = &insn_buf[0];
1190411903 bool issrc, isneg;
1190511904 u32 off_reg;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t