mirror of
https://github.com/soypat/lneto.git
synced 2026-08-21 06:59:04 +00:00
DHCPv4+Debug (#170)
* DHCPv4+Debug: add RawData method and improve Logging semantics with configured logger instead of default * add xnet.LogAllocs
This commit is contained in:
@@ -44,6 +44,9 @@ type Frame struct {
|
||||
buf []byte
|
||||
}
|
||||
|
||||
// RawData returns the underlying frame buffer.
|
||||
func (frm Frame) RawData() []byte { return frm.buf }
|
||||
|
||||
// OptionsPayload returns the options portion of the DHCP frame. May be zero lengthed.
|
||||
func (frm Frame) OptionsPayload() []byte {
|
||||
return frm.buf[OptionsOffset:]
|
||||
|
||||
Reference in New Issue
Block a user