github fortio/fortio v1.6.4
fortio v1.6.4 - small new utility function in fnet package

latest releases: v1.63.7, v1.63.6, v1.63.5...
3 years ago
  • new fnet.SmallReadUntil library utility function (#377):
// SmallReadUntil will read one byte at a time until stopByte is found and up to max bytes total.
// Returns what was read (without the stop byte when found), whether the stop byte was found, 
// whether an error occurred (eof...).
// Because we read one by one directly (no buffer) this should only be used for short variable length
// preamble type read.
func SmallReadUntil(r io.Reader, stopByte byte, max int) ([]byte, bool, error)

Don't miss a new fortio release

NewReleases is sending notifications on new releases.