path: root/app
diff options
authorChristoph Gysin <>2015-09-29 09:53:01 +0300
committerThomas Monjalon <>2015-10-22 17:50:51 +0200
commit7499ef45c375998a67c65b7eac0d9d4639ac5ac4 (patch)
tree000671b7a0d516e298a0caa1859307f0660fd031 /app
parentd08d304508a8a8caf255baf622ab65db1fec952c (diff)
eal: fix C++ build
'virtual' is a keyword and can't be used if the code is to compile with C++ compilers. If rte_devargs.h was included in C++ code, compilation with clang++ failed with an error. g++ did not fail, but only because of a bug that treats it as an anonymous struct with a decl-specifier which it ignores. This simply renames the member to 'virt'. Reported-by: Ming Zhao <> Signed-off-by: Christoph Gysin <> Acked-by: Cristian Dumitrescu <> Acked-by: David Marchand <>
Diffstat (limited to 'app')
1 files changed, 2 insertions, 2 deletions
diff --git a/app/test/test_devargs.c b/app/test/test_devargs.c
index f7fc59c..049f32d 100644
--- a/app/test/test_devargs.c
+++ b/app/test/test_devargs.c
@@ -91,8 +91,8 @@ test_devargs(void)
if (rte_eal_devargs_add(RTE_DEVTYPE_VIRTUAL, "eth_ring1,k1=val,k2=val2") < 0)
goto fail;
devargs = TAILQ_FIRST(&devargs_list);
- if (strncmp(devargs->virtual.drv_name, "eth_ring1",
- sizeof(devargs->virtual.drv_name)) != 0)
+ if (strncmp(devargs->virt.drv_name, "eth_ring1",
+ sizeof(devargs->virt.drv_name)) != 0)
goto fail;
if (!devargs->args || strcmp(devargs->args, "k1=val,k2=val2") != 0)
goto fail;