summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMaxime Coquelin <maxime.coquelin@redhat.com>2016-07-12 11:30:25 +0200
committerThomas Monjalon <thomas.monjalon@6wind.com>2016-07-15 22:15:21 +0200
commit9cca159efa1ebe0463a2805d309394c9eb1b532a (patch)
treea1383370c54e62ad935fa92513b8f197a7e7146d /drivers
parentacbff5c67ea77e7db50614d5ddaa4dfb3deccde2 (diff)
downloaddpdk-9cca159efa1ebe0463a2805d309394c9eb1b532a.zip
dpdk-9cca159efa1ebe0463a2805d309394c9eb1b532a.tar.gz
dpdk-9cca159efa1ebe0463a2805d309394c9eb1b532a.tar.xz
net/virtio-user: fix build with gcc 6
The error is reported using test build script: $ scripts/test-build.sh x86_64-native-linuxapp-gcc ... drivers/net/virtio/virtio_user_ethdev.c:345:2: error: this ‘if’ clause does not guard... [-Werror=misleading-indentation] if (rte_kvargs_count(kvlist, VIRTIO_USER_ARG_PATH) == 1) ^~ Fixes: 404bd6bfe360 ("net/virtio-user: fix return value not checked") Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com> Acked-by: Yuanhan Liu <yuanhan.liu@linux.intel.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/virtio/virtio_user_ethdev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/virtio/virtio_user_ethdev.c b/drivers/net/virtio/virtio_user_ethdev.c
index 782d7d3..6b4f66e 100644
--- a/drivers/net/virtio/virtio_user_ethdev.c
+++ b/drivers/net/virtio/virtio_user_ethdev.c
@@ -342,7 +342,7 @@ virtio_user_pmd_devinit(const char *name, const char *params)
goto end;
}
- if (rte_kvargs_count(kvlist, VIRTIO_USER_ARG_PATH) == 1)
+ if (rte_kvargs_count(kvlist, VIRTIO_USER_ARG_PATH) == 1) {
ret = rte_kvargs_process(kvlist, VIRTIO_USER_ARG_PATH,
&get_string_arg, &path);
if (ret < 0) {
@@ -350,7 +350,7 @@ virtio_user_pmd_devinit(const char *name, const char *params)
VIRTIO_USER_ARG_PATH);
goto end;
}
- else {
+ } else {
PMD_INIT_LOG(ERR, "arg %s is mandatory for virtio-user\n",
VIRTIO_USER_ARG_QUEUE_SIZE);
goto end;