dev.dpdk.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] eal: Fixed EAL option --base-virtaddr
@ 2014-06-19 15:35 Pablo de Lara
       [not found] ` <1403192122-25496-1-git-send-email-pablox.de.lara.guarch-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Pablo de Lara @ 2014-06-19 15:35 UTC (permalink / raw)
  To: dev-VfR2kkLFssw

From: Pablo de Lara <pablo.de.lara.guarch-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

When parsing EAL option --base-virtaddr
errno was not being set to 0 before calling strtoull,
therefore function might fail unnecesarily.

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
---
 lib/librte_eal/linuxapp/eal/eal.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/lib/librte_eal/linuxapp/eal/eal.c b/lib/librte_eal/linuxapp/eal/eal.c
index 6994303..d204387 100644
--- a/lib/librte_eal/linuxapp/eal/eal.c
+++ b/lib/librte_eal/linuxapp/eal/eal.c
@@ -562,6 +562,7 @@ eal_parse_base_virtaddr(const char *arg)
 	char *end;
 	uint64_t addr;
 
+	errno = 0;
 	addr = strtoull(arg, &end, 16);
 
 	/* check for errors */
-- 
1.7.0.7

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-06-19 15:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-19 15:35 [PATCH] eal: Fixed EAL option --base-virtaddr Pablo de Lara
     [not found] ` <1403192122-25496-1-git-send-email-pablox.de.lara.guarch-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-06-19 15:51   ` Burakov, Anatoly
     [not found]     ` <C6ECDF3AB251BE4894318F4E451236976CC9D75C-kPTMFJFq+rF9qrmMLTLiibfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2014-06-19 15:59       ` 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).