From 8fa66795b862d92602ccc6834c9e862b9b37066d Mon Sep 17 00:00:00 2001 From: Samuel Gomes Date: Wed, 24 Jan 2024 19:01:36 +0530 Subject: [PATCH] Make FILES work for cases where fileSpec does not contain a directory --- internal/c/libqb/src/filesystem.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/internal/c/libqb/src/filesystem.cpp b/internal/c/libqb/src/filesystem.cpp index 3ac184b6b..a8eaa03ce 100644 --- a/internal/c/libqb/src/filesystem.cpp +++ b/internal/c/libqb/src/filesystem.cpp @@ -792,6 +792,9 @@ void sub_files(qbs *str, int32_t passed) { } else { std::string d; filepath_split(fileSpec, d, pathName); + if (d.empty()) + d = "./"; // default to the current directory if one is not specified + directory = FS_GetFQN(d.c_str()); } } else {