SDL: SDL_sysfilesystem.c (SDL_GetBasePath): fixed the solaris code path.

From a3d7dd24646298e27c0a95f3c5f8beaac03f4c9e Mon Sep 17 00:00:00 2001
From: Ozkan Sezer <[EMAIL REDACTED]>
Date: Fri, 2 Dec 2022 06:23:30 +0300
Subject: [PATCH] SDL_sysfilesystem.c (SDL_GetBasePath): fixed the solaris code
 path.

Reference issue: https://github.com/libsdl-org/SDL/pull/6681
---
 src/filesystem/unix/SDL_sysfilesystem.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/filesystem/unix/SDL_sysfilesystem.c b/src/filesystem/unix/SDL_sysfilesystem.c
index ac3fe32c3550..e80c5bad4338 100644
--- a/src/filesystem/unix/SDL_sysfilesystem.c
+++ b/src/filesystem/unix/SDL_sysfilesystem.c
@@ -221,8 +221,9 @@ SDL_GetBasePath(void)
         }
 #endif
     }
-#if defined(__SOLARIS__)
-    else {
+
+#if defined(__SOLARIS__)  /* try this as a fallback if /proc didn't pan out */
+    if (!retval) {
         const char *path = getexecname();
         if ((path != NULL) && (path[0] == '/')) { /* must be absolute path... */
             retval = SDL_strdup(path);