From a11a66fb63ecf8219578a2ddb8dfd47345f90941 Mon Sep 17 00:00:00 2001 From: Samuel Gomes Date: Sun, 10 Dec 2023 11:25:01 +0530 Subject: [PATCH] Rename startDir to g_startDir --- internal/c/libqb.cpp | 6 +++--- internal/c/libqb/include/filesystem.h | 2 +- internal/c/libqb/src/filesystem.cpp | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/internal/c/libqb.cpp b/internal/c/libqb.cpp index f87882a46..bd6c800b7 100644 --- a/internal/c/libqb.cpp +++ b/internal/c/libqb.cpp @@ -36143,9 +36143,9 @@ int main(int argc, char *argv[]) { singlespace = qbs_new_cmem(1, 0); singlespace->chr[0] = 32; - // store _CWD$ for recall using _STARTDIR$ in startDir - startDir = qbs_new(0, 0); - qbs_set(startDir, func__cwd()); + // store _CWD$ for recall using _STARTDIR$ in g_startDir + g_startDir = qbs_new(0, 0); + qbs_set(g_startDir, func__cwd()); // switch to directory of this EXE file // http://stackoverflow.com/questions/1023306/finding-current-executables-path-without-proc-self-exe diff --git a/internal/c/libqb/include/filesystem.h b/internal/c/libqb/include/filesystem.h index 5137b3c08..4c4dd3976 100644 --- a/internal/c/libqb/include/filesystem.h +++ b/internal/c/libqb/include/filesystem.h @@ -4,7 +4,7 @@ struct qbs; -extern qbs *startDir; +extern qbs *g_startDir; qbs *func__cwd(); qbs *func__dir(qbs *context); diff --git a/internal/c/libqb/src/filesystem.cpp b/internal/c/libqb/src/filesystem.cpp index 4b9419334..776d9e533 100644 --- a/internal/c/libqb/src/filesystem.cpp +++ b/internal/c/libqb/src/filesystem.cpp @@ -267,11 +267,11 @@ int32 func__fileexists(qbs *file) { #endif } -qbs *startDir = NULL; // set on startup +qbs *g_startDir = nullptr; // set on startup qbs *func__startdir() { qbs *temp = qbs_new(0, 1); - qbs_set(temp, startDir); + qbs_set(temp, g_startDir); return temp; }