X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=datapath%2Fdatapath.c;fp=datapath%2Fdatapath.c;h=fe37ec1ed4c1c7a1bd6ebc9b7d482d32fcc8f15d;hb=a842e7b093786019292998fa192d4ed7d228d686;hp=5ee915740db43a40df31a54b2eac7b25913b9171;hpb=51a66e1bc935c50afe955da947cf253adf115751;p=sliver-openvswitch.git diff --git a/datapath/datapath.c b/datapath/datapath.c index 5ee915740..fe37ec1ed 100644 --- a/datapath/datapath.c +++ b/datapath/datapath.c @@ -1326,10 +1326,11 @@ static int do_execute(struct datapath *dp, const struct odp_execute *execute) if (execute->length < ETH_HLEN || execute->length > 65535) goto error; - err = -ENOMEM; actions = flow_actions_alloc(execute->n_actions); - if (!actions) + if (IS_ERR(actions)) { + err = PTR_ERR(actions); goto error; + } err = -EFAULT; if (copy_from_user(actions->actions, execute->actions,