* [dpdk-stable] [PATCH v1] lib/power: fix incorrect parameter to strerror
@ 2019-11-25 15:00 David Hunt
2019-11-25 23:27 ` [dpdk-stable] [dpdk-dev] " Thomas Monjalon
0 siblings, 1 reply; 2+ messages in thread
From: David Hunt @ 2019-11-25 15:00 UTC (permalink / raw)
To: dev; +Cc: john.mcnamara, David Hunt, stable
Should be passing errno rather than ret, which could be negative.
Coverity issue: 350362
Fixes: 9dc843eb273b ("power: extend guest channel API for reading")
Cc: stable@dpdk.org
Signed-off-by: David Hunt <david.hunt@intel.com>
---
lib/librte_power/guest_channel.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/librte_power/guest_channel.c b/lib/librte_power/guest_channel.c
index 439cd2f38..b984d55bc 100644
--- a/lib/librte_power/guest_channel.c
+++ b/lib/librte_power/guest_channel.c
@@ -148,7 +148,7 @@ int power_guest_channel_read_msg(void *pkt,
return -1;
} else if (ret < 0) {
RTE_LOG(ERR, GUEST_CHANNEL, "Error occurred during poll function: %s\n",
- strerror(ret));
+ strerror(errno));
return -1;
}
--
2.17.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [dpdk-stable] [dpdk-dev] [PATCH v1] lib/power: fix incorrect parameter to strerror
2019-11-25 15:00 [dpdk-stable] [PATCH v1] lib/power: fix incorrect parameter to strerror David Hunt
@ 2019-11-25 23:27 ` Thomas Monjalon
0 siblings, 0 replies; 2+ messages in thread
From: Thomas Monjalon @ 2019-11-25 23:27 UTC (permalink / raw)
To: David Hunt; +Cc: dev, john.mcnamara, stable
25/11/2019 16:00, David Hunt:
> Should be passing errno rather than ret, which could be negative.
>
> Coverity issue: 350362
> Fixes: 9dc843eb273b ("power: extend guest channel API for reading")
> Cc: stable@dpdk.org
>
> Signed-off-by: David Hunt <david.hunt@intel.com>
Applied, thanks
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-11-25 23:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-25 15:00 [dpdk-stable] [PATCH v1] lib/power: fix incorrect parameter to strerror David Hunt
2019-11-25 23:27 ` [dpdk-stable] [dpdk-dev] " Thomas Monjalon
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).