Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 204dfb4

Browse files
[Impeller] Add an autorelease pool to the GoldenTests fixture (#43323)
1 parent cd9ce66 commit 204dfb4

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

impeller/golden_tests/golden_tests.cc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
#include <sstream>
88

9+
#include "flutter/fml/platform/darwin/scoped_nsautorelease_pool.h"
910
#include "impeller/aiks/canvas.h"
1011
#include "impeller/entity/contents/conical_gradient_contents.h"
1112
#include "impeller/geometry/path_builder.h"
@@ -59,6 +60,10 @@ class GoldenTests : public ::testing::Test {
5960
}
6061

6162
private:
63+
// This must be placed before any other members that may use the
64+
// autorelease pool.
65+
fml::ScopedNSAutoreleasePool autorelease_pool_;
66+
6267
std::unique_ptr<MetalScreenshoter> screenshoter_;
6368
};
6469

0 commit comments

Comments
 (0)