mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-12 12:14:36 +03:00
Use String_eq wrapper instead of raw strcmp
This commit is contained in:

committed by
BenBE

parent
04cf590967
commit
69efa94f9f
@ -303,7 +303,7 @@ static int valueDigitColor(unsigned int value) {
|
||||
static void SystemdMeter_display(ATTR_UNUSED const Object* cast, RichString* out) {
|
||||
char buffer[16];
|
||||
|
||||
int color = (systemState && 0 == strcmp(systemState, "running")) ? METER_VALUE_OK : METER_VALUE_ERROR;
|
||||
int color = (systemState && String_eq(systemState, "running")) ? METER_VALUE_OK : METER_VALUE_ERROR;
|
||||
RichString_writeAscii(out, CRT_colors[color], systemState ? systemState : "N/A");
|
||||
|
||||
RichString_appendAscii(out, CRT_colors[METER_TEXT], " (");
|
||||
|
Reference in New Issue
Block a user