From 01737ed66b9bfcb2b983a8834060f3bae9bf7da1 Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Thu, 9 Apr 2015 15:44:26 -0300 Subject: [PATCH] Reset to the default scheme, not the last one. --- Settings.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Settings.c b/Settings.c index 6bd2e12e..68e2af5a 100644 --- a/Settings.c +++ b/Settings.c @@ -208,8 +208,7 @@ static bool Settings_read(Settings* this, const char* fileName, int cpuCount) { this->delay = atoi(option[1]); } else if (String_eq(option[0], "color_scheme")) { this->colorScheme = atoi(option[1]); - if (this->colorScheme < 0) this->colorScheme = 0; - if (this->colorScheme >= LAST_COLORSCHEME) this->colorScheme = LAST_COLORSCHEME - 1; + if (this->colorScheme < 0 || this->colorScheme >= LAST_COLORSCHEME) this->colorScheme = 0; } else if (String_eq(option[0], "left_meters")) { Settings_readMeters(this, option[1], 0); readMeters = true;