commit 8059c606ef926a920089a0a4fe36de15e610ad7b
parent 33cca93aefa426d04d9950c42baa0b5c2f9dbebf
Author: Jack Mordaunt <jackmordaunt.dev@gmail.com>
Date: Sun, 20 Sep 2026 07:39:23 -0300
scan: answer the elevation question on every platform
`elevated` was declared only in the Windows half of the package, but main calls
it unconditionally, so the tree did not compile for Linux or macOS at all. The
build was green only because nobody had pointed the compiler anywhere else.
Nothing here can reach a volume yet either way, since `resolve` still returns
Unsupported_Platform off Windows. Whoever implements that implements this beside
it: on unix the answer is file permissions on the device, not a process token.
Diffstat:
1 file changed, 12 insertions(+), 0 deletions(-)
diff --git a/scan/target_other.odin b/scan/target_other.odin
@@ -8,3 +8,15 @@ resolve :: proc(input: string, allocator := context.allocator) -> (t: Target, er
_, _ = input, allocator
return {}, .Unsupported_Platform
}
+
+/*
+Whether this process can open a raw volume handle.
+
+No target resolves on this platform yet, so nothing here can reach a volume however
+this answers. A platform that implements `resolve` implements this beside it: on unix
+raw device access is a matter of file permissions rather than a token, so the honest
+answer is whether the device opens.
+*/
+elevated :: proc() -> bool {
+ return false
+}