mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-12 12:14:36 +03:00
Fix segmentation fault when column name is NULL.
So, some columns (ex: SECATTR) can be sortable now.
This commit is contained in:

committed by
Christian Göttsche

parent
6787c43097
commit
59ef15b2ad
@ -135,15 +135,6 @@ ColumnsPanel* ColumnsPanel_new(Settings* settings) {
|
||||
return this;
|
||||
}
|
||||
|
||||
int ColumnsPanel_fieldNameToIndex(const char* name) {
|
||||
for (int j = 1; j <= Platform_numberOfFields; j++) {
|
||||
if (String_eq(name, Process_fields[j].name)) {
|
||||
return j;
|
||||
}
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
|
||||
void ColumnsPanel_update(Panel* super) {
|
||||
ColumnsPanel* this = (ColumnsPanel*) super;
|
||||
int size = Panel_size(super);
|
||||
|
Reference in New Issue
Block a user