1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 11:02:59 +02:00

don't read Block after it is freed. This fixes PR1684

llvm-svn: 42204
This commit is contained in:
Chris Lattner 2007-09-21 18:25:53 +00:00
parent 505fcba791
commit e82eb89d0f

View File

@ -1301,7 +1301,9 @@ public:
ValuesSet.InsertNode(Value, Where);
Values.push_back(Value);
} else {
// Already exists, reuse the previous one.
delete Block;
Block = cast<DIEBlock>(Value);
}
Die->AddValue(Attribute, Block->BestForm(), Value);