fix: USTAR prefix-field parsing and directory-aware chdir
Two ramdisk fixes exposed by shipping the C++ header tree: Paths longer than 100 characters (libstdc++'s pb_ds detail headers) are split by USTAR across the name field and the 155-byte prefix field at offset 345. The parser only read the name field, so the tails of 7 deep header paths appeared as bogus root-level entries while the real paths were missing. The parser now joins prefix + '/' + name, and MaxNameLen grows to 260 to hold the full combined path. SYS_CHDIR validated non-root targets by opening them as files, which only ever worked because directories used to be openable. It now uses the ReadDir probe, which fails for nonexistent paths and regular files on all backends (ext2/fat32 already validate the inode type). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -12,4 +12,4 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#define MONTAUK_BUILD_NUMBER 21
|
||||
#define MONTAUK_BUILD_NUMBER 22
|
||||
|
||||
Reference in New Issue
Block a user