Skip to content

Commit

Permalink
change dim order because of colours in reboot_required (netdata#19111)
Browse files Browse the repository at this point in the history
  • Loading branch information
ilyam8 authored Nov 30, 2024
1 parent d9f7159 commit 4b1e0f6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/collectors/proc.plugin/run_reboot_required.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,15 +57,15 @@ int do_run_reboot_required(int update_every, usec_t dt) {
update_every,
RRDSET_TYPE_LINE);

rd_required = rrddim_add(st, "required", NULL, 1, 1, RRD_ALGORITHM_ABSOLUTE);
rd_not_required = rrddim_add(st, "not_required", NULL, 1, 1, RRD_ALGORITHM_ABSOLUTE);
rd_required = rrddim_add(st, "required", NULL, 1, 1, RRD_ALGORITHM_ABSOLUTE);
}

struct stat buf;
bool exists = (stat(signal_file_path, &buf) == 0);

rrddim_set_by_pointer(st, rd_required, exists ? 1 : 0);
rrddim_set_by_pointer(st, rd_not_required, exists ? 0 : 1);
rrddim_set_by_pointer(st, rd_required, exists ? 1 : 0);
rrdset_done(st);

return 0;
Expand Down

0 comments on commit 4b1e0f6

Please sign in to comment.