fixes bug in channel API which caused endOfTrack to be sent early