Skip to content

Commit

Permalink
Minor: s/TC_ACT_OK/r0/
Browse files Browse the repository at this point in the history
Signed-off-by: Zhichuan Liang <gray.liang@isovalent.com>
  • Loading branch information
jschwinger233 authored and brb committed Jul 4, 2023
1 parent 24a5b42 commit 7ed9082
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libpcap/compile.go
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ func adjustEbpf(insts asm.Instructions, opts cbpfc.EBPFOpts) (newInsts asm.Instr
insts = append(insts,
asm.Mov.Imm(asm.R0, 0).WithSymbol("result"), // r0 = 0
asm.JNE.Imm(opts.Result, 0, "continue"), // if %result != 0 (match): jump to continue
asm.Return().WithSymbol("return"), // else return TC_ACT_OK
asm.Return().WithSymbol("return"), // else return r0
asm.Mov.Imm(asm.R0, 0).WithSymbol("continue"),
)

Expand Down

0 comments on commit 7ed9082

Please sign in to comment.