From: Ben Pfaff Date: Fri, 26 Apr 2013 18:13:04 +0000 (-0700) Subject: netdev: Make 'smap' variable const in netdev_set_qos(). X-Git-Tag: sliver-openvswitch-1.10.90-3~16^2~45 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=edfbe9f7bc340fb696b6f3a20fa47a536610eb38;p=sliver-openvswitch.git netdev: Make 'smap' variable const in netdev_set_qos(). This makes this code more obviously thread-safe. Signed-off-by: Ben Pfaff --- diff --git a/lib/netdev.c b/lib/netdev.c index 156984ad1..434e2572e 100644 --- a/lib/netdev.c +++ b/lib/netdev.c @@ -1115,7 +1115,7 @@ netdev_set_qos(struct netdev *netdev, if (class->set_qos) { if (!details) { - static struct smap empty = SMAP_INITIALIZER(&empty); + static const struct smap empty = SMAP_INITIALIZER(&empty); details = ∅ } return class->set_qos(netdev, type, details);