projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
645a86f
)
Remove a memory leak from MetadataTest.
author
Jeffrey Yasskin
<jyasskin@google.com>
Sat, 13 Mar 2010 01:39:20 +0000
(
01:39
+0000)
committer
Jeffrey Yasskin
<jyasskin@google.com>
Sat, 13 Mar 2010 01:39:20 +0000
(
01:39
+0000)
Tested: valgrind --leak-check=full unittests/VMCore/Debug/VMCoreTests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98412
91177308
-0d34-0410-b5e6-
96231b3b80d8
unittests/VMCore/MetadataTest.cpp
patch
|
blob
|
history
diff --git
a/unittests/VMCore/MetadataTest.cpp
b/unittests/VMCore/MetadataTest.cpp
index 13bf27e5d8fa4b01cdf6caebdc2a436f0ba54ce7..04db486cd87102a4f1a8da896e4969eed4081d3e 100644
(file)
--- a/
unittests/VMCore/MetadataTest.cpp
+++ b/
unittests/VMCore/MetadataTest.cpp
@@
-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);