fix SDL issue (CID 1518459) (#19287)

This commit is contained in:
Wanglei Shen
2023-08-21 20:24:59 +08:00
committed by GitHub
parent 90f6500871
commit 7c273dc2c5

View File

@@ -257,7 +257,7 @@ std::vector<std::vector<int>> get_streams_info_table(const int input_streams,
n_threads_per_stream = static_cast<int>(n_threads / n_streams);
}
} else {
while (n_streams * 2 <= n_threads_per_stream) {
while ((n_streams * 2 <= n_threads_per_stream) && (n_threads_per_stream > 1)) {
n_threads_per_stream = static_cast<int>(n_threads_per_stream / 2);
n_streams = static_cast<int>(n_threads / n_threads_per_stream);
}