The nl_sock_transact_multiple function enters in an infinite loop,
when invalid error, EINVAL, is returned by nl_sock_transact_multiple__.
EINVAL is the error returned by the latter function when a driver
request fails.
Signed-off-by: Sorin Vinturis <svinturis@cloudbasesolutions.com>
Reported-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Reported-at: https://github.com/openvswitch/ovs-issues/issues/57
Acked-by: Eitan Eliahu <eliahue@vmware.com>
Acked-by: Nithin Raju <nithin@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
&reply_len, NULL)) {
/* XXX: Map to a more appropriate error. */
error = EINVAL;
+ VLOG_DBG_RL(&rl, "fatal driver failure: %s",
+ ovs_lasterror_to_string());
break;
}
} else if (error) {
VLOG_ERR_RL(&rl, "transaction error (%s)", ovs_strerror(error));
nl_sock_record_errors__(transactions, n, error);
+ if (error != EAGAIN) {
+ /* A fatal error has occurred. Abort the rest of
+ * transactions. */
+ break;
+ }
}
}
}