Archived
Fix test fixture lifetimes for sanitizer validation
Avoid empty-payload fwrite, retain the JSON embedding value during iteration, and release fake pinned allocations between Flash-Next redeclarations. Test-only fixes used by the HYV3 sanitizer run.
This commit is contained in:
1 parent
91fc4192aa
commit
a6702f8db5
3 files changed
+9
-4
No files matched your search
@@ -60,7 +60,8 @@ void write_shard(const std::string& path, const std::vector<T>& ts) {
|
||||
const uint64_t n = hdr.size();
|
||||
std::fwrite(&n, 8, 1, f);
|
||||
std::fwrite(hdr.data(), 1, hdr.size(), f);
|
||||
for (const T& t : ts) std::fwrite(t.bytes.data(), 1, t.bytes.size(), f);
|
||||
for (const T& t : ts)
|
||||
if (!t.bytes.empty()) std::fwrite(t.bytes.data(), 1, t.bytes.size(), f);
|
||||
std::fclose(f);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user