From 014436eb4ad0c403647939a2461e1fe4a7967c89 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 16 Apr 2020 17:24:28 +0200 Subject: fix(3p/nix): ValueMap, VectorVector: Use traceable_allocator We want to *trace* the 'Value *' arrays, not garbage-collect them! Otherwise the vectors/maps can end up pointing to nowhere. Backported from: https://github.com/NixOS/nix/commit/10e17eaa5802a3c368eee8408821828072e76ba7 Change-Id: I30dc94caa80c9d982e7a14bc67ba2d065e8203aa Reviewed-on: https://cl.tvl.fyi/c/depot/+/1252 Tested-by: BuildkiteCI Reviewed-by: isomer --- third_party/nix/src/libexpr/value.hh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'third_party') diff --git a/third_party/nix/src/libexpr/value.hh b/third_party/nix/src/libexpr/value.hh index 01b9fd3a216d..7308dd31933a 100644 --- a/third_party/nix/src/libexpr/value.hh +++ b/third_party/nix/src/libexpr/value.hh @@ -242,9 +242,9 @@ void mkPath(Value& v, const char* s); not included. */ size_t valueSize(Value& v); -typedef std::vector > ValueVector; +typedef std::vector> ValueVector; typedef std::map, - gc_allocator > > + traceable_allocator>> ValueMap; } // namespace nix -- cgit 1.4.1