Terminate pointer-only descriptor traversal

This commit is contained in:
2026-10-25 21:18:35 +00:00
parent 7889ebddfb
commit 2736ddfbf2
5 changed files with 165 additions and 30 deletions

View File

@@ -168,8 +168,10 @@ func schemaSecretRoot(schema *schemaDescriptor, path Path) (Path, bool) {
walked := Path{}
for _, segment := range path.segments {
walked.segments = append(walked.segments, segment)
for current.kind == descriptorPointer {
current = current.element
var ok bool
current, ok = terminalDescriptor(current)
if !ok {
return Path{}, false
}
switch current.kind {
case descriptorStruct: