Developer Tools

llama.cpp fixes isolate working directory bug in v10331

llama.cpp v10331 patches isolate path handling for safer tool execution

Deep Dive

The maintainers of the popular local LLM inference framework [llama.cpp](https://github.com/ggerganov/llama.cpp) pushed v10331 (commit `7ba604f`) on August 8 to address a subtle but critical path-handling issue in the server component. The bug occurred when `get_info()` was called without an explicit `cwd` parameter. Instead of returning the isolate's dedicated working directory, it defaulted to the server process's working directory—potentially exposing host paths where tools were never intended to run. The fix modifies `get_info()` to query the isolate directly for its working directory and only fall back to the process directory when tools execute on the host system. A redundant comment was also removed in the same patch.

llama.cpp v10331 supports a wide array of platforms and accelerators, including CPU, Vulkan, ROCm, OpenVINO, SYCL, CUDA (12.4/13.3), HIP, ACL Graph, and platform-specific builds for macOS (Apple Silicon & Intel), Windows (x64/arm64), Linux (x64/arm64/s390x), Android (arm64), and openEuler (x86/aarch64). The release also includes updated UI assets. Users running self-hosted LLM servers or agentic tools should update to avoid unintended path leakage.

Key Points
  • llama.cpp v10331 fixes a bug where get_info() returned incorrect isolate working directories, risking unintended path exposure
  • Update affects Linux, Windows, macOS, Android, and openEuler across CPU and GPU backends (CUDA, ROCm, Vulkan, SYCL, etc.)
  • Supports 20+ platform/build combinations; UI assets and CUDA 12.4/13.3 DLLs included

Why It Matters

Critical path-handling fix improves sandboxing and reliability for local LLM deployments and agentic workflows.

📬 Get the top 10 AI stories daily