From b463e1f265628f97967a01ce0a2cf18afe7b7aa3 Mon Sep 17 00:00:00 2001 From: Vadim Kochan Date: Sun, 14 May 2017 08:52:08 +0300 Subject: trafgen: parser: Use proto_field_set_xxx where it is possible Use proto_field_set_xxx(field, ...) instead of proto_hdr_field_set_xxx(hdr, fid, ...) to be more generic and do not depend on 'hdr' variable. Signed-off-by: Vadim Kochan Signed-off-by: Tobias Klauser --- trafgen_proto.h | 1 + 1 file changed, 1 insertion(+) (limited to 'trafgen_proto.h') diff --git a/trafgen_proto.h b/trafgen_proto.h index d863287..56e7271 100644 --- a/trafgen_proto.h +++ b/trafgen_proto.h @@ -155,6 +155,7 @@ extern void proto_field_set_u32(struct proto_field *field, uint32_t val); extern uint32_t proto_field_get_u32(struct proto_field *field); extern void proto_field_set_be16(struct proto_field *field, uint16_t val); extern void proto_field_set_be32(struct proto_field *field, uint32_t val); +extern void proto_field_set_bytes(struct proto_field *field, const uint8_t *bytes); extern void proto_field_func_add(struct proto_field *field, struct proto_field_func *func); -- cgit v1.2.3-54-g00ecf