Skip to content

ggml : don't crash when backend search path can't be read - #28271

Merged
ggerganov merged 1 commit into
ggml-org:masterfrom
angt:ggml-don-t-crash-when-backend-search-path-can-t-be-read
Sep 4, 2026
Merged

ggerganov merged 1 commit into
ggml-org:masterfrom
angt:ggml-don-t-crash-when-backend-search-path-can-t-be-read

Conversation

@angt

@angt angt commented Sep 2, 2026 •

Copy link
Copy Markdown
Member

Overview

Use std::error_code overloads of fs::current_path() and fs::directory_iterator in ggml_backend_load_best() so an inaccessible search path (WebDAV mount, removed CWD) is skipped instead of terminating the process with an uncaught filesystem_error.

Additional information

Found while benching in a windows VM:

error: libc++abi: terminating due to uncaught exception of type std::__1::__fs::filesystem::filesystem_error: filesystem error: in directory_iterator::directory_iterator(...): The network path was not found. ["Z:\"]

Requirements

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
@github-actions github-actions Bot added the ggml changes relating to the ggml tensor library for machine learning label Sep 2, 2026
@angt
angt requested a review from ggerganov September 2, 2026 21:18
@ggerganov
ggerganov merged commit 4cbe8b0 into ggml-org:master Sep 4, 2026
20 of 26 checks passed
@BrewTestBot BrewTestBot mentioned this pull request Sep 4, 2026
1 task done
agentdavo pushed a commit to agentdavo/llama.cpp that referenced this pull request Sep 6, 2026
…8271)

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
(cherry picked from commit 4cbe8b0)
x1250 pushed a commit to x1250/llama.cpp that referenced this pull request Sep 9, 2026
…8271)

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
zbrad pushed a commit to zbrad/llama.cpp that referenced this pull request Sep 10, 2026
…8271)

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
pl752 pushed a commit to pl752/llama.cpp that referenced this pull request Sep 15, 2026
…8271)

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
zsogitbe pushed a commit to zsogitbe/llama.cpp that referenced this pull request Sep 17, 2026
…8271)

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
frostyautumnleaf pushed a commit to frostyautumnleaf/llama.cpp that referenced this pull request Oct 5, 2026
…8271)

Use std::error_code overloads of fs::current_path() and
fs::directory_iterator in ggml_backend_load_best() so an
inaccessible search path (WebDAV mount, removed CWD) is
skipped instead of terminating the process with an uncaught
filesystem_error.

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ggml changes relating to the ggml tensor library for machine learning

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants