1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-08 19:46:02 +01:00

libutil: Throw if str("contents") not found

This was broken in 7aa3e7e3a5 (since 2.25).

(cherry picked from commit 242f362567)
This commit is contained in:
Samuel Connelly 2025-10-03 18:41:01 -04:00 committed by Sergei Zimmerman
parent f2b45e014b
commit d9601db10d
No known key found for this signature in database

View file

@ -187,8 +187,10 @@ static void parse(FileSystemObjectSink & sink, Source & source, const CanonPath
tag = getString(); tag = getString();
} }
if (tag == "contents") if (tag != "contents")
parseContents(crf, source); throw badArchive("expected tag 'contents', got '%s'", tag);
parseContents(crf, source);
expectTag(")"); expectTag(")");
}); });