From: Thomas Monjalon <thomas@monjalon.net>
To: dev@dpdk.org
Cc: reshma.pattan@intel.com
Subject: [dpdk-dev] [PATCH] examples/l3fwd-power: fix build with gcc 4
Date: Sat, 29 Jun 2019 10:55:07 +0200 [thread overview]
Message-ID: <20190629085507.31808-1-thomas@monjalon.net> (raw)
error: ‘for’ loop initial declarations are only allowed in C99 mode
Fixes: 609e79841fcf ("examples/l3fwd-power: add telemetry mode")
Cc: reshma.pattan@intel.com
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
---
examples/l3fwd-power/main.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/examples/l3fwd-power/main.c b/examples/l3fwd-power/main.c
index fb2a9d62f..99c1208ce 100644
--- a/examples/l3fwd-power/main.c
+++ b/examples/l3fwd-power/main.c
@@ -2468,10 +2468,12 @@ main(int argc, char **argv)
rte_eal_mp_remote_launch(main_empty_poll_loop, NULL,
SKIP_MASTER);
} else {
+ unsigned int i;
+
/* Init metrics library */
rte_metrics_init(rte_socket_id());
/** Register stats with metrics library */
- for (unsigned int i = 0; i < num_telstats; i++)
+ for (i = 0; i < num_telstats; i++)
ptr_strings[i] = telstats_strings[i].name;
ret = rte_metrics_reg_names(ptr_strings, num_telstats);
--
2.21.0
next reply other threads:[~2019-06-29 8:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-29 8:55 Thomas Monjalon [this message]
2019-06-29 12:27 ` Thomas Monjalon
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=20190629085507.31808-1-thomas@monjalon.net \
--to=thomas@monjalon.net \
--cc=dev@dpdk.org \
--cc=reshma.pattan@intel.com \
/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).