From 1d9644cd1971cc45ecbdfab11f0f452a01645dfb Mon Sep 17 00:00:00 2001 From: jkim Date: Thu, 28 Aug 2008 22:41:31 +0000 Subject: [PATCH] Move comments to the right places. --- tools/regression/bpf/bpf_filter/bpf_test.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tools/regression/bpf/bpf_filter/bpf_test.c b/tools/regression/bpf/bpf_filter/bpf_test.c index d39878a7c8ef..91386d7e09ff 100644 --- a/tools/regression/bpf/bpf_filter/bpf_test.c +++ b/tools/regression/bpf/bpf_filter/bpf_test.c @@ -133,17 +133,17 @@ bpf_validate(const struct bpf_insn *f, int len) return (1); for (i = 0; i < len; ++i) { - /* - * Check that that jumps are forward, and within - * the code block. - */ p = &f[i]; /* - * Check that the instruction is valid. + * Check that the code is valid. */ if ((p->code & 0xff00) || !(bpf_code_map[p->code >> 4] & (1 << (p->code & 0xf)))) return (0); + /* + * Check that that jumps are forward, and within + * the code block. + */ if (BPF_CLASS(p->code) == BPF_JMP) { register int from = i + 1;