From: Hengqi Chen <hengqi.chen@gmail.com>
To: Andrii Nakryiko <andrii.nakryiko@gmail.com>
Cc: Alexei Starovoitov <alexei.starovoitov@gmail.com>,
bpf <bpf@vger.kernel.org>, Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Andrii Nakryiko <andrii@kernel.org>, Yonghong Song <yhs@fb.com>,
John Fastabend <john.fastabend@gmail.com>,
Martin KaFai Lau <kafai@fb.com>, Song Liu <songliubraving@fb.com>
Subject: Re: [PATCH bpf-next 2/2 v2] selftests/bpf: Test bpf_skc_to_unix_sock() helper
Date: Wed, 20 Oct 2021 21:41:15 +0800 [thread overview]
Message-ID: <4fdcdd5e-a741-dcf1-67b0-ec5a8b4f288a@gmail.com> (raw)
In-Reply-To: <CAEf4BzaiCMSnzXntfbcmSDO4u7TM-f0OO0NZThvbYA9GR6A7dw@mail.gmail.com>
On 2021/10/20 1:02 AM, Andrii Nakryiko wrote:
> On Tue, Oct 19, 2021 at 8:23 AM Hengqi Chen <hengqi.chen@gmail.com> wrote:
>>
>> Thanks for the review.
>>
>> On 10/19/21 9:46 AM, Alexei Starovoitov wrote:
>>> On Thu, Oct 7, 2021 at 7:14 AM Hengqi Chen <hengqi.chen@gmail.com> wrote:
>>>> +
>>>> + sockaddr.sun_family = AF_UNIX;
>>>> + strcpy(sockaddr.sun_path, sock_path);
>>>
>>> please use strncpy.
>>
>> Will do.
>
> please also run checkpatch.pl and confirm you haven't introduced new
> styling issues. As one example (and please fix this up in the next
> revision), you are using C++-style comments.
>
Thanks, Andrii.
Forgot to run checkpatch scripts before sending the email.
Will do that in future patches.
>>
>>>
>>>> + len = sizeof(sockaddr);
>>>> + unlink(sock_path);
>>>
>>> please use abstract socket to avoid unlink and potential race.
>>>
>>
>> Will switch to abstract socket and update the BPF program.
prev parent reply other threads:[~2021-10-20 13:41 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-07 14:13 [PATCH bpf-next 0/2 v2] Add bpf_skc_to_unix_sock() helper Hengqi Chen
2021-10-07 14:13 ` [PATCH bpf-next 1/2 v2] bpf: " Hengqi Chen
2021-10-07 14:13 ` [PATCH bpf-next 2/2 v2] selftests/bpf: Test " Hengqi Chen
2021-10-19 1:46 ` Alexei Starovoitov
2021-10-19 15:23 ` Hengqi Chen
2021-10-19 17:02 ` Andrii Nakryiko
2021-10-20 13:41 ` Hengqi Chen [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4fdcdd5e-a741-dcf1-67b0-ec5a8b4f288a@gmail.com \
--to=hengqi.chen@gmail.com \
--cc=alexei.starovoitov@gmail.com \
--cc=andrii.nakryiko@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=john.fastabend@gmail.com \
--cc=kafai@fb.com \
--cc=songliubraving@fb.com \
--cc=yhs@fb.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox