X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Fofp-parse.c;h=de7cd9c72e17603dc096a21c330e7113baf2ab67;hb=033419e81cac78924359f375e4ca558380f094c4;hp=f1a4cb44967c4f53595a779783f4a399ad52954a;hpb=dd8101bc538cdad7a99f61666760fa79e6c047af;p=openvswitch diff --git a/lib/ofp-parse.c b/lib/ofp-parse.c index f1a4cb44..de7cd9c7 100644 --- a/lib/ofp-parse.c +++ b/lib/ofp-parse.c @@ -726,7 +726,7 @@ parse_reg_value(struct cls_rule *rule, int reg_idx, const char *value) /* Convert 'string' (as described in the Flow Syntax section of the ovs-ofctl * man page) into 'pf'. If 'actions' is specified, an action must be in * 'string' and may be expanded or reallocated. */ -static void +void parse_ofp_str(struct flow_mod *fm, uint8_t *table_idx, struct ofpbuf *actions, char *string) { @@ -871,8 +871,8 @@ parse_ofp_flow_mod_str(struct list *packets, enum nx_flow_format *cur_format, * 'stream' and the command is always OFPFC_ADD. Returns false if end-of-file * is reached before reading a flow, otherwise true. */ bool -parse_ofp_add_flow_file(struct list *packets, enum nx_flow_format *cur, - FILE *stream) +parse_ofp_flow_mod_file(struct list *packets, enum nx_flow_format *cur, + FILE *stream, uint16_t command) { struct ds s; bool ok; @@ -880,7 +880,7 @@ parse_ofp_add_flow_file(struct list *packets, enum nx_flow_format *cur, ds_init(&s); ok = ds_get_preprocessed_line(&s, stream) == 0; if (ok) { - parse_ofp_flow_mod_str(packets, cur, ds_cstr(&s), OFPFC_ADD); + parse_ofp_flow_mod_str(packets, cur, ds_cstr(&s), command); } ds_destroy(&s);