pub fn read_variable_byte_integer(
cursor: &mut usize,
buf: &[u8],
) -> Result<usize, MqttError<ErrorPlaceHolder>>
Expand description
Reads a variable-byte integer from the buffer, advancing the cursor.
This is a common encoding scheme in MQTT for packet lengths.