net: move stack variable at top of VLAN strip function
authorAndy Green <andy@warmcat.com>
Sat, 12 May 2018 02:00:17 +0000 (10:00 +0800)
committerThomas Monjalon <thomas@monjalon.net>
Sun, 13 May 2018 20:45:25 +0000 (22:45 +0200)
commit5a7e5accc695e5cf0ed840f59042dba4cbe0aae3
tree36acd0efef27ef5e835fd00111b584d20a10bcb6
parentf7f18e92a51276f1e23a0595f59615f79323b358
net: move stack variable at top of VLAN strip function

In function 'rte_vlan_strip':
rte_ether.h:357:2:
warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
  struct vlan_hdr *vh = (struct vlan_hdr *)(eh + 1);

Fixes: c974021a5949 ("ether: add soft vlan encap/decap")
Cc: stable@dpdk.org
Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
lib/librte_net/rte_ether.h