listing/thread: fix wrong column index crash
Run cargo lints / Lint on ${{ matrix.build }} (linux-amd64, ubuntu-latest, stable, x86_64-unknown-linux-gnu) (pull_request) Successful in 6m4s Details
Run Tests / Test on ${{ matrix.build }} (linux-amd64, ubuntu-latest, stable, x86_64-unknown-linux-gnu) (pull_request) Successful in 10m58s Details

columns[0] was jused in every for loop instead of columns[n], which
would make the debug_assert_eq(area generation, column generation) panic

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
pull/379/head
Manos Pitsidianakis 2024-04-17 13:17:34 +03:00
parent 11f3077b06
commit 8a16cf6db4
Signed by: Manos Pitsidianakis
GPG Key ID: 7729C7707F7E09D0
1 changed files with 1 additions and 1 deletions

View File

@ -1090,7 +1090,7 @@ impl ThreadListing {
let columns = &mut self.data_columns.columns;
for n in 0..=4 {
let area = columns[n].area().nth_row(idx);
columns[0].grid_mut().clear_area(area, row_attr);
columns[n].grid_mut().clear_area(area, row_attr);
}
*self.rows.entries.get_mut(idx).unwrap() = ((thread_hash, env_hash), strings);