From: Easwar Hariharan <eahariha@linux.microsoft.com>
To: Ani Sinha <anisinha@redhat.com>
Cc: Shradha Gupta <shradhagupta@linux.microsoft.com>,
linux-kernel@vger.kernel.org, linux-hyperv@vger.kernel.org,
"K. Y. Srinivasan" <kys@microsoft.com>,
Haiyang Zhang <haiyangz@microsoft.com>,
Wei Liu <wei.liu@kernel.org>, Dexuan Cui <decui@microsoft.com>,
Long Li <longli@microsoft.com>, Olaf Hering <olaf@aepfle.de>,
Shradha Gupta <shradhagupta@microsoft.com>
Subject: Re: [PATCH v3] hv/hv_kvp_daemon: Handle IPv4 and Ipv6 combination for keyfile format
Date: Mon, 18 Mar 2024 10:16:59 -0700 [thread overview]
Message-ID: <066c4b0c-c8a5-4abd-9456-20b0352ee1ab@linux.microsoft.com> (raw)
In-Reply-To: <C740F1C4-CA2A-425B-8E60-0EF5C2C15270@redhat.com>
On 3/18/2024 10:12 AM, Ani Sinha wrote:
>
>
<snip>
>>> + }
>>> +
>>> + if (strlen(output_str)) {
>>> + output_str[strlen(output_str) - 1] = '\0';
>>
>> You don't need this since you're using strncat which adds its own '\0'.
>
> If I understand this correctly, this code simply eliminates the extra “,” character in the end. Therefore it is needed.
> Since it is not obvious, in the previous review and before, I asked the author to add a comment to explain this clearly.
>
>> I wasn't quite able to follow along
>> on the discussion between Ani and you, so putting this in here in case it wasn't already mentioned.
>>
Ah, great, that makes sense. I did see that it was destroying data but didn't spend enough time to think through
what data it was destroying, and if that was a feature or a bug. Thanks for calling it out!
- Easwar
next prev parent reply other threads:[~2024-03-18 17:17 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-18 2:45 [PATCH v3] hv/hv_kvp_daemon: Handle IPv4 and Ipv6 combination for keyfile format Shradha Gupta
2024-03-18 4:21 ` Ani Sinha
2024-03-18 4:56 ` Ani Sinha
2024-03-18 15:27 ` Shradha Gupta
2024-03-18 16:19 ` Easwar Hariharan
2024-03-18 17:12 ` Ani Sinha
2024-03-18 17:16 ` Easwar Hariharan [this message]
2024-03-18 18:45 ` Shradha Gupta
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=066c4b0c-c8a5-4abd-9456-20b0352ee1ab@linux.microsoft.com \
--to=eahariha@linux.microsoft.com \
--cc=anisinha@redhat.com \
--cc=decui@microsoft.com \
--cc=haiyangz@microsoft.com \
--cc=kys@microsoft.com \
--cc=linux-hyperv@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=longli@microsoft.com \
--cc=olaf@aepfle.de \
--cc=shradhagupta@linux.microsoft.com \
--cc=shradhagupta@microsoft.com \
--cc=wei.liu@kernel.org \
/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