From: "Burakov, Anatoly" <anatoly.burakov@intel.com>
To: Bruce Richardson <bruce.richardson@intel.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH] eal: support strlcat function
Date: Thu, 17 Jan 2019 11:55:55 +0000 [thread overview]
Message-ID: <262b52ab-159f-fa08-ef71-f565264d1b8e@intel.com> (raw)
In-Reply-To: <20190117110022.GB289580@bricha3-MOBL.ger.corp.intel.com>
On 17-Jan-19 11:00 AM, Bruce Richardson wrote:
> On Thu, Jan 17, 2019 at 10:39:02AM +0000, Burakov, Anatoly wrote:
>> On 16-Jan-19 12:48 PM, Bruce Richardson wrote:
>>> Add the strlcat function to DPDK to exist alongside the strlcpy one.
>>> While strncat is generally safe for use for concatenation, the API for
>>> the strlcat function is perhaps a little nicer to use, and supports
>>> truncation detection.
>>>
>>> See commit: 5364de644a4b ("eal: support strlcpy function") for more
>>> details on the function selection logic, since we only should be using
>>> the DPDK-provided version when no system-provided version is present.
>>>
>>> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com> ---
>>
>> <...>
>>
>>> static int test_string_fns(void) { if (test_rte_strsplit() < 0)
>>> return -1; + if (test_rte_strlcat() < 0) + return -1;
>>> return 0; }
>>>
>>
>> Unrelated, but do we also need to test strlcpy, strscpy and other
>> functions that were introduced?
>>
>
> Yes, I think that would be advisable. I imagine the easiest way to test
> them is to do as I have here in running comparisons with a range of inputs,
> especially boundary conditions, against a known-good version for platforms
> that have the functions built-in.
> As always, volunteers and patches welcome... :-)
/action hides
>
> /Bruce
>
--
Thanks,
Anatoly
next prev parent reply other threads:[~2019-01-17 11:55 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-16 12:48 Bruce Richardson
2019-01-17 10:39 ` Burakov, Anatoly
2019-01-17 11:00 ` Bruce Richardson
2019-01-17 11:55 ` Burakov, Anatoly [this message]
2019-01-17 13:10 ` Ferruh Yigit
2019-01-17 16:30 ` [dpdk-dev] [PATCH v2] " Bruce Richardson
2019-01-17 16:50 ` Ferruh Yigit
2019-01-17 17:05 ` Pattan, Reshma
2019-01-17 17:30 ` [dpdk-dev] [PATCH v3] " Bruce Richardson
2019-02-12 9:27 ` Thomas Monjalon
2019-04-16 14:29 ` Kevin Traynor
2019-04-16 14:29 ` Kevin Traynor
2019-04-16 14:37 ` Bruce Richardson
2019-04-16 14:37 ` Bruce Richardson
2019-04-16 16:03 ` Ferruh Yigit
2019-04-16 16:03 ` Ferruh Yigit
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=262b52ab-159f-fa08-ef71-f565264d1b8e@intel.com \
--to=anatoly.burakov@intel.com \
--cc=bruce.richardson@intel.com \
--cc=dev@dpdk.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;
as well as URLs for NNTP newsgroup(s).