Adding an assert to help catch possible buffer underruns.