either a ProtoField or an array of protofields

mbuf 2018-03-05 13:12:07.097246 UTC

local hb_proto = Proto ("Heartbeat", "A Heartbeat")
local hb_message_proto = Proto ("HeartbeatMessage", "A Heartbeat Message")

local hb_fields = {
  size       = ProtoField.uint32 ("hb.size", "Size",       base.DEC),
  field_type = ProtoField.uint16 ("hb.type", "Field Type", base.DEC),
}

local hb_message_fields = {
  id   = ProtoField.uint16 ("hb_message.id",   "ID",           base.DEC),
  type = ProtoField.uint8  ("hb_message.type", "Message Type", base.DEC),
}

hb_proto.fields = hb_fields
hb_message_proto.fields = hb_message_fields -- Error causing line!