1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 20:51:52 +01:00

Remove a memory leak from MetadataTest.

Tested: valgrind --leak-check=full unittests/VMCore/Debug/VMCoreTests
llvm-svn: 98412
This commit is contained in:
Jeffrey Yasskin 2010-03-13 01:39:20 +00:00
parent 9058ef4163
commit 5dea722948

View File

@ -132,9 +132,9 @@ TEST(NamedMDNodeTest, Search) {
MDNode *Nodes[2] = { n, n2 };
Module *M = new Module("MyModule", Context);
Module M("MyModule", Context);
const char *Name = "llvm.NMD1";
NamedMDNode *NMD = NamedMDNode::Create(Context, Name, &Nodes[0], 2, M);
NamedMDNode *NMD = NamedMDNode::Create(Context, Name, &Nodes[0], 2, &M);
std::string Str;
raw_string_ostream oss(Str);
NMD->print(oss);