netdev-vport: Make netdev_vport_patch_peer() return a malloc()'d string.
authorBen Pfaff <blp@nicira.com>
Wed, 31 Jul 2013 21:09:30 +0000 (14:09 -0700)
committerBen Pfaff <blp@nicira.com>
Sat, 10 Aug 2013 04:23:19 +0000 (21:23 -0700)
commit161b6042d853f54e609415a671aaebe859ee94a2
treedebecfcb12690abeee31d14dc4f1eb8610bbb83f
parent9dc63482bbeae23dd57b0f885a3fd26b44656844
netdev-vport: Make netdev_vport_patch_peer() return a malloc()'d string.

When threading comes into the picture there arises the possibility of a
race between netdev_vport_patch_peer()'s caller using the returned string
and another caller changing the peer.  It is safer to return a copy.

Signed-off-by: Ben Pfaff <blp@nicira.com>
lib/netdev-vport.c
lib/netdev-vport.h
ofproto/ofproto-dpif.c