* [dpdk-dev] [PATCH] lib/lpm: fix return value of rte_lpm_create
@ 2018-01-31 12:40 Anatoly Burakov
2018-01-31 13:11 ` Bruce Richardson
0 siblings, 1 reply; 3+ messages in thread
From: Anatoly Burakov @ 2018-01-31 12:40 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson, zhiyong.yang
LPM library is supposed to return NULL pointer on an attempt
to call rte_lpm_create with an existing name.
Fixes: 134975073af3 ("lib: remove unnecessary pointer cast")
Cc: zhiyong.yang@intel.com
Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
---
lib/librte_lpm/rte_lpm.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/librte_lpm/rte_lpm.c b/lib/librte_lpm/rte_lpm.c
index d464dbd..efbbbca 100644
--- a/lib/librte_lpm/rte_lpm.c
+++ b/lib/librte_lpm/rte_lpm.c
@@ -254,6 +254,7 @@ rte_lpm_create_v1604(const char *name, int socket_id,
if (strncmp(name, lpm->name, RTE_LPM_NAMESIZE) == 0)
break;
}
+ lpm = NULL;
if (te != NULL) {
rte_errno = EEXIST;
--
2.7.4
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] lib/lpm: fix return value of rte_lpm_create
2018-01-31 12:40 [dpdk-dev] [PATCH] lib/lpm: fix return value of rte_lpm_create Anatoly Burakov
@ 2018-01-31 13:11 ` Bruce Richardson
2018-01-31 13:29 ` Burakov, Anatoly
0 siblings, 1 reply; 3+ messages in thread
From: Bruce Richardson @ 2018-01-31 13:11 UTC (permalink / raw)
To: Anatoly Burakov; +Cc: dev, zhiyong.yang
On Wed, Jan 31, 2018 at 12:40:59PM +0000, Anatoly Burakov wrote:
> LPM library is supposed to return NULL pointer on an attempt
> to call rte_lpm_create with an existing name.
>
> Fixes: 134975073af3 ("lib: remove unnecessary pointer cast")
> Cc: zhiyong.yang@intel.com
>
> Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
> ---
This looks a duplicate of http://dpdk.org/dev/patchwork/patch/34739/, is
that correct?
If so, please review/test/ack that patch to confirm it fixes the issues
you see too.
Thanks,
/Bruce
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-dev] [PATCH] lib/lpm: fix return value of rte_lpm_create
2018-01-31 13:11 ` Bruce Richardson
@ 2018-01-31 13:29 ` Burakov, Anatoly
0 siblings, 0 replies; 3+ messages in thread
From: Burakov, Anatoly @ 2018-01-31 13:29 UTC (permalink / raw)
To: Bruce Richardson; +Cc: dev, zhiyong.yang
On 31-Jan-18 1:11 PM, Bruce Richardson wrote:
> On Wed, Jan 31, 2018 at 12:40:59PM +0000, Anatoly Burakov wrote:
>> LPM library is supposed to return NULL pointer on an attempt
>> to call rte_lpm_create with an existing name.
>>
>> Fixes: 134975073af3 ("lib: remove unnecessary pointer cast")
>> Cc: zhiyong.yang@intel.com
>>
>> Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
>> ---
>
> This looks a duplicate of http://dpdk.org/dev/patchwork/patch/34739/, is
> that correct?
> If so, please review/test/ack that patch to confirm it fixes the issues
> you see too.
>
> Thanks,
> /Bruce
>
You're correct, missed that. Thanks!
--
Thanks,
Anatoly
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-01-31 13:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-31 12:40 [dpdk-dev] [PATCH] lib/lpm: fix return value of rte_lpm_create Anatoly Burakov
2018-01-31 13:11 ` Bruce Richardson
2018-01-31 13:29 ` Burakov, Anatoly
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).