--- zzzz-none-000/linux-3.10.107/samples/seccomp/bpf-helper.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/samples/seccomp/bpf-helper.c 2021-02-04 17:41:59.000000000 +0000 @@ -10,6 +10,7 @@ */ #include +#include #include #include "bpf-helper.h" @@ -63,6 +64,11 @@ { struct __bpf_label *begin = labels->labels, *end; int id; + + if (labels->count == BPF_LABELS_MAX) { + fprintf(stderr, "Too many labels\n"); + exit(1); + } if (labels->count == 0) { begin->label = label; begin->location = 0xffffffff;