From 93fccb3a8cdd1a8ffc8aef5e773b2ccc967fd0c9 Mon Sep 17 00:00:00 2001 From: Antonio Giner Date: Thu, 13 Jun 2024 08:49:14 +0200 Subject: [PATCH] Update to upstream Switchres (2.2.1). --- 3rdparty/switchres/switchres.cpp | 2 +- 3rdparty/switchres/switchres.h | 2 +- 3rdparty/switchres/switchres_main.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/3rdparty/switchres/switchres.cpp b/3rdparty/switchres/switchres.cpp index b83cdd0ff145c..76dbdd6982cab 100644 --- a/3rdparty/switchres/switchres.cpp +++ b/3rdparty/switchres/switchres.cpp @@ -89,7 +89,7 @@ switchres_manager::switchres_manager() display()->set_monitor("generic_15"); display()->set_modeline("auto"); display()->set_lcd_range("auto"); - for (int i = 0; i++ < MAX_RANGES;) display()->set_crt_range(i, "auto"); + for (int i = 0; i < MAX_RANGES; i++) display()->set_crt_range(i, "auto"); display()->set_screen("auto"); display()->set_modeline_generation(true); display()->set_lock_unsupported_modes(true); diff --git a/3rdparty/switchres/switchres.h b/3rdparty/switchres/switchres.h index 5a28c03134c63..c072cc12aa490 100644 --- a/3rdparty/switchres/switchres.h +++ b/3rdparty/switchres/switchres.h @@ -27,7 +27,7 @@ //============================================================ #ifndef SWITCHRES_VERSION -#define SWITCHRES_VERSION "2.2.0" +#define SWITCHRES_VERSION "2.2.1" #endif diff --git a/3rdparty/switchres/switchres_main.cpp b/3rdparty/switchres/switchres_main.cpp index d2c555c235afb..5514fde012282 100644 --- a/3rdparty/switchres/switchres_main.cpp +++ b/3rdparty/switchres/switchres_main.cpp @@ -375,7 +375,7 @@ int main(int argc, char **argv) monitor_range *range = &switchres.display()->range[mode->range]; edid_from_modeline(mode, range, switchres.display()->monitor(), &edid); - char file_name[strlen(switchres.display()->monitor()) + 4]; + char file_name[strlen(switchres.display()->monitor()) + 5]; sprintf(file_name, "%s.bin", switchres.display()->monitor()); FILE *file = fopen(file_name, "wb");