summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlastair Poole <mail@alastairpoole.com>2021-11-03 07:22:48 +0000
committerAlastair Poole <mail@alastairpoole.com>2021-11-03 07:22:48 +0000
commit8393a979e660f2c49f9bfde678474584b13cf54b (patch)
tree3f3c31906ce0d501247142b221d8cbac01797129
parentcda6a898a557ed0834b41dea7fe4ea978609b334 (diff)
ui_cpu: exit on garbled visual.
Did some testing that garbled the config...there should be a check here. This shouldn't ordinarily happen.
-rw-r--r--src/bin/ui/ui_cpu.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/bin/ui/ui_cpu.c b/src/bin/ui/ui_cpu.c
index 5f202f2..d78337c 100644
--- a/src/bin/ui/ui_cpu.c
+++ b/src/bin/ui/ui_cpu.c
@@ -254,6 +254,11 @@ ui_cpu_win_add(Evisum_Ui *ui)
254 elm_table_pack(tb, box, 0, 0, 1, 1); 254 elm_table_pack(tb, box, 0, 0, 1, 1);
255 255
256 vis = ui_cpu_visual_by_name(ui->cpu.visual); 256 vis = ui_cpu_visual_by_name(ui->cpu.visual);
257 if (!vis)
258 {
259 fprintf(stderr, "FATAL: unknown CPU visual (check your config)\n");
260 exit(1);
261 }
257 pd = vis->func(box); 262 pd = vis->func(box);
258 pd->ui = ui; 263 pd->ui = ui;
259 264