summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjinke18 <[email protected]>2024-07-30 23:35:48 +0800
committerjinke18 <[email protected]>2024-07-30 23:35:48 +0800
commitad6f76074557007d56b6755f387c9e60ea12a278 (patch)
tree40954bb3c7f557232363aef31cce3752875fb791
parentd40756de311f62d81a8a02b1701eb809586a0c0f (diff)
make pattern more strict
-rw-r--r--xmake/modules/detect/sdks/find_vstudio.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/modules/detect/sdks/find_vstudio.lua b/xmake/modules/detect/sdks/find_vstudio.lua
index ca49d8d07..0bc374204 100644
--- a/xmake/modules/detect/sdks/find_vstudio.lua
+++ b/xmake/modules/detect/sdks/find_vstudio.lua
@@ -191,7 +191,7 @@ function _load_vcvarsall(vcvarsall, vsver, arch, opt)
-- then parse it from `WindowsSdkBinPath`, such as: `C:\\Program Files (x86)\\Windows Kits\\8.1\\bin`
local WindowsSdkBinPath = variables["WindowsSdkBinPath"]
if WindowsSdkBinPath then
- WindowsSDKVersion = string.match(WindowsSdkBinPath, "\\(%d+%.?%d*)\\bin")
+ WindowsSDKVersion = string.match(WindowsSdkBinPath, "\\(%d+%.%d+)\\bin$")
if WindowsSDKVersion then
variables["WindowsSDKVersion"] = WindowsSDKVersion
end