Re: [PATCH] bpf.2: Fix bug in example

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/9/19 6:32 PM, Oded Elisha wrote:
> Signed-off-by: Oded Elisha <oded123456@xxxxxxxxx>

Thank you, Oded. Patch applied.

Cheers,

Michael

> ---
>  man2/bpf.2 | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/man2/bpf.2 b/man2/bpf.2
> index d4dc687f6..f089535ed 100644
> --- a/man2/bpf.2
> +++ b/man2/bpf.2
> @@ -988,7 +988,7 @@ main(int argc, char **argv)
>      };
>  
>      prog_fd = bpf_prog_load(BPF_PROG_TYPE_SOCKET_FILTER, prog,
> -                            sizeof(prog), "GPL");
> +                            sizeof(prog) / sizeof(prog[0]), "GPL");
>  
>      sock = open_raw_sock("lo");
>  
> 


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/



[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux