fix calculation of n_priority_streams