-enum ofperr
-ofp_bundle_commit(struct ofconn *ofconn, uint32_t id, uint16_t flags)
-{
- struct hmap *bundles;
- struct ofp_bundle *bundle;
- enum ofperr error = 0;
- struct ofp_bundle_entry *msg;
-
- bundles = ofconn_get_bundles(ofconn);
- bundle = ofp_bundle_find(bundles, id);
-
- if (!bundle) {
- return OFPERR_OFPBFC_BAD_ID;
- }
- if (bundle->flags != flags) {
- error = OFPERR_OFPBFC_BAD_FLAGS;
- } else {
- LIST_FOR_EACH (msg, node, &bundle->msg_list) {
- /* XXX: actual commit */
- error = OFPERR_OFPBFC_MSG_FAILED;
- }
- }
-
- ofp_bundle_remove(ofconn, bundle);
- return error;
-}
-