# initial buffer length

**URL:** <https://community.zeek.org/t/initial-buffer-length/3625>\
**Category:** Zeek\
**Created:** [May 27, 2015, 11:52am UTC](https://community.zeek.org/t/initial-buffer-length/3625 "2015-05-27T11:52:13Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Abdelkarim\_benkhadra](https://avatars.discourse-cdn.com/v4/letter/a/ee59a6/32.png) [@Abdelkarim\_benkhadra](https://community.zeek.org/u/Abdelkarim_benkhadra)\
**Post date:** [May 27, 2015, 11:52am UTC](https://community.zeek.org/t/initial-buffer-length/3625/1 "2015-05-27T11:52:13Z")

</div>

Hi,

in myproto-protocol.pac, i have:

type myproto\_PDU(is\_orig: bool) = record {  
header: myproto\_Header;  
//restofdefinition;  
} &length=header.msgSize;

type myproto\_Header = record {  
//some fields;  
msgSize: uint16;  
//restoffields;  
};  
msgSize represents the length of the PDU.  
and when "make"ing bro i get “cannot determine initial buffer length for type myproto\_PDU”.  
i tryed some random values like &length=60 and it works fine.  
i took the modbus analyzer as an exemple to write myproto analyzer but without success.  
any ideas?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/zeek/original/1X/f09d732bc2cc7c7cc7e35db67cf4e1d5233ce7a7.png) [@system](https://community.zeek.org/u/system)\
**Post date:** [May 6, 2022, 3:42pm UTC](https://community.zeek.org/t/initial-buffer-length/3625/2 "2022-05-06T15:42:43Z")

</div>


