slight rework of the previous speex fix

need a length check really, so split out the tests