Merge pull request #532 from davidgfnet/master
authorAutechre <libretro@gmail.com>
Sat, 31 Jul 2021 17:57:15 +0000 (19:57 +0200)
committerGitHub <noreply@github.com>
Sat, 31 Jul 2021 17:57:15 +0000 (19:57 +0200)
Fix initialization on Frontends without variable support.

frontend/libretro.c

index d0a0da7..59e986e 100644 (file)
@@ -1634,7 +1634,9 @@ static void update_variables(bool in_flight)
    var.value = NULL;
    var.key = "pcsx_rearmed_drc";
 
-   if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
+   if (!environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var))
+      var.value = "enabled";
+
    {
       R3000Acpu *prev_cpu = psxCpu;
 #if defined(LIGHTREC)