diff options
| author | ruki <[email protected]> | 2022-11-04 22:05:21 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-11-04 22:05:21 +0800 |
| commit | efd90e2a9ffd2420607184828237aaf567ea079b (patch) | |
| tree | 706d57c420396f12c973aac55e7531b7cb4f40c6 | |
| parent | 780fbef81eb5a3daf5783566dcaed0e17bc79a44 (diff) | |
| parent | e97189c91af7eb44883894d6b8cff04a28ec9700 (diff) | |
Merge pull request #3019 from mtortonesi/sandbox_lib_detect_find_path._find-fix
Fix sandbox_lib_detect_find_path._find function.
| -rw-r--r-- | xmake/core/sandbox/modules/import/lib/detect/find_path.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xmake/core/sandbox/modules/import/lib/detect/find_path.lua b/xmake/core/sandbox/modules/import/lib/detect/find_path.lua index d881d1072..a88562a76 100644 --- a/xmake/core/sandbox/modules/import/lib/detect/find_path.lua +++ b/xmake/core/sandbox/modules/import/lib/detect/find_path.lua @@ -37,7 +37,7 @@ function sandbox_lib_detect_find_path._find(filedir, name) local filepath = results[1] if filepath then -- we need translate name first, https://github.com/xmake-io/xmake-repo/issues/1315 - local p = filepath:find(path.pattern(path.translate(name))) + local p = filepath:lastof(path.pattern(path.translate(name))) if p then filepath = path.translate(filepath:sub(1, p - 1)) if os.isdir(filepath) then |
