ReadUint32 reads a uint32 and sets error on bounds violation
(err *Error)
| 359 | |
| 360 | // ReadUint32 reads a uint32 and sets error on bounds violation |
| 361 | func (b *ByteBuffer) ReadUint32(err *Error) uint32 { |
| 362 | if b.readerIndex+4 > len(b.data) { |
| 363 | if !b.fill(4, err) { |
| 364 | return 0 |
| 365 | } |
| 366 | } |
| 367 | i := binary.LittleEndian.Uint32(b.data[b.readerIndex:]) |
| 368 | b.readerIndex += 4 |
| 369 | return i |
| 370 | } |
| 371 | |
| 372 | // ReadUint64 reads a uint64 and sets error on bounds violation |
| 373 | func (b *ByteBuffer) ReadUint64(err *Error) uint64 { |
no test coverage detected