added length of bytes decoded from the remaining length decode function