src/os/root_openat.go | 4 ++-- diff --git a/src/os/root_openat.go b/src/os/root_openat.go index 1875877dd23dd47c688da18dda5b50f7f9c1615f..62e6be665a9233ebf679145d0e0dfe277222491b 100644 --- a/src/os/root_openat.go +++ b/src/os/root_openat.go @@ -109,7 +109,7 @@ func rootMkdir(r *Root, name string, perm FileMode) error { flags := uint(doInRootCreatingDirectory) switch runtime.GOOS { - case "linux", "windows": + case "linux", "windows", "openbsd": // These platforms do not follow "symlink" on "mkdir symlink/". // (POSIX.1-2024 4.16 says that the trailing slash should cause // resolution to follow the symlink, but we're trying to match @@ -185,7 +185,7 @@ return struct{}{}, &PathError{Op: "mkdirat", Err: err} } flags := uint(doInRootCreatingDirectory) switch runtime.GOOS { - case "linux", "windows": + case "linux", "windows", "openbsd": flags |= doInRootNoHandleTerminalSlash // see rootMkdir } _, err := doInRoot(r, fullname, flags, openDirFunc, openLastComponentFunc)