Apply suggestions from code review

Co-authored-by: BenBE <BenBE@geshi.org>
This commit is contained in:
Nathan Scott
2021-08-17 15:42:10 +10:00
committed by GitHub
parent c7f634ec21
commit d5ff5c48a8
2 changed files with 2 additions and 2 deletions

View File

@ -174,7 +174,7 @@ static Htop_Reaction actionSetSortColumn(State* st) {
char* name = NULL;
if (fields[i] >= LAST_PROCESSFIELD) {
DynamicColumn* column = Hashtable_get(dynamicColumns, fields[i]);
if (column == NULL)
if (!column)
continue;
name = xStrdup(column->caption ? column->caption : column->name);
} else {