X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fdpif-linux.c;h=fd08e640264b866c0a60224125e54979e962dc4c;hb=8996f83642d6bd73a72d5864a1c6a66448b49214;hp=75cff0c43d87ec0381c0b69e378e76c35477b9dd;hpb=002d4a3c44a7a42fdfe5f40185fe3af0ed697454;p=sliver-openvswitch.git diff --git a/lib/dpif-linux.c b/lib/dpif-linux.c index 75cff0c43..fd08e6402 100644 --- a/lib/dpif-linux.c +++ b/lib/dpif-linux.c @@ -1254,6 +1254,15 @@ dpif_linux_vport_transact(const struct dpif_linux_vport *request, assert((reply != NULL) == (bufp != NULL)); + error = dpif_linux_init(); + if (error) { + if (reply) { + *bufp = NULL; + dpif_linux_vport_init(reply); + } + return error; + } + request_buf = ofpbuf_new(1024); dpif_linux_vport_to_ofpbuf(request, request_buf); error = nl_sock_transact(genl_sock, request_buf, bufp);