summaryrefslogtreecommitdiffstats
path: root/src/corelib
diff options
context:
space:
mode:
authorFabian Kosmale <fabian.kosmale@qt.io>2024-04-30 12:01:18 +0200
committerFabian Kosmale <fabian.kosmale@qt.io>2024-04-30 23:33:37 +0200
commitaa161b1e4e151bd8a019da9797f9e0d717e6d00f (patch)
treeb9ef0a85d35ddc40931dfe56af59634d3bd62302 /src/corelib
parent09ea47f8113bdce437253b19a91f739aeef7a333 (diff)
qtconf: Add comment to clarify code handling env vars
The string handling is not immediately clear, unless one already knows what it is supposed to do. Change-Id: Icd5746513d760d478f03c8aded3669b06b692a87 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Ahmad Samir <a.samirh78@gmail.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'src/corelib')
-rw-r--r--src/corelib/global/qlibraryinfo.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp
index 92729b06f1..1b03733d2a 100644
--- a/src/corelib/global/qlibraryinfo.cpp
+++ b/src/corelib/global/qlibraryinfo.cpp
@@ -554,6 +554,10 @@ QString QLibraryInfoPrivate::path(QLibraryInfo::LibraryPath p, UsageMode usageMo
}
qsizetype startIndex = 0;
+ /* We support placeholders of the form $(<ENV_VAR>) in qt.conf.
+ The loop below tries to find all such placeholders, and replaces
+ them with the actual value of the ENV_VAR environment variable
+ */
while (true) {
startIndex = ret.indexOf(u'$', startIndex);
if (startIndex < 0)