[all-commits] [llvm/llvm-project] a17386: [libc] Implement mkdtemp (#222106)

Jeff Bailey via All-commits all-commits at lists.llvm.org
Wed Sep 9 10:54:30 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a173863e63415ae54b5d0abf1bc5897c61604e5f
      https://github.com/llvm/llvm-project/commit/a173863e63415ae54b5d0abf1bc5897c61604e5f
  Author: Jeff Bailey <jbailey at raspberryginger.com>
  Date:   2026-09-09 (Wed, 09 Sep 2026)

  Changed paths:
    M libc/config/linux/aarch64/entrypoints.txt
    M libc/config/linux/riscv/entrypoints.txt
    M libc/config/linux/x86_64/entrypoints.txt
    M libc/include/stdlib.yaml
    M libc/src/stdlib/CMakeLists.txt
    M libc/src/stdlib/linux/CMakeLists.txt
    A libc/src/stdlib/linux/mkdtemp.cpp
    A libc/src/stdlib/linux/mkstemp.cpp
    A libc/src/stdlib/linux/mktemp_util.h
    A libc/src/stdlib/mkdtemp.h
    R libc/src/stdlib/mkstemp.cpp
    M libc/src/stdlib/mkstemp.h
    M libc/test/src/stdlib/CMakeLists.txt
    A libc/test/src/stdlib/mkdtemp_test.cpp

  Log Message:
  -----------
  [libc] Implement mkdtemp (#222106)

Add the POSIX mkdtemp entrypoint for Linux targets (aarch64, riscv,
x86_64).

Extract the shared template replacement and random character retry loop
into linux/mktemp_util.h, relocating mkstemp to linux/mkstemp.cpp and
reusing the helper across both entrypoints.

Add comprehensive unit tests covering directory creation, permissions,
uniqueness, and invalid template handling.

Assisted-by: Automated tooling, human reviewed.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list