aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/System/DynamicLibrary.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-05-12 18:13:11 +0000
committerChris Lattner <sabre@nondot.org>2006-05-12 18:13:11 +0000
commit1971e8a77b2ecb264e34e64abf0876b43fec62eb (patch)
treebdb987a7008766d22650fe8f18eb1242c29a4ccc /llvm/lib/System/DynamicLibrary.cpp
parent1fe2d2c6009554fae29b3208d092a96acbca2de7 (diff)
downloadllvm-1971e8a77b2ecb264e34e64abf0876b43fec62eb.zip
llvm-1971e8a77b2ecb264e34e64abf0876b43fec62eb.tar.gz
llvm-1971e8a77b2ecb264e34e64abf0876b43fec62eb.tar.bz2
Fix iterator invalidation bug, identified by Coverity.
llvm-svn: 28257
Diffstat (limited to 'llvm/lib/System/DynamicLibrary.cpp')
-rw-r--r--llvm/lib/System/DynamicLibrary.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/System/DynamicLibrary.cpp b/llvm/lib/System/DynamicLibrary.cpp
index 0c179fc..056fed0 100644
--- a/llvm/lib/System/DynamicLibrary.cpp
+++ b/llvm/lib/System/DynamicLibrary.cpp
@@ -93,6 +93,7 @@ DynamicLibrary::~DynamicLibrary() {
if (*I == a_handle) {
// Note: don't use the swap/pop_back trick here. Order is important.
OpenedHandles.erase(I);
+ return;
}
}
}