summaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-06-15 09:11:47 +0000
committerBill Wendling <isanbard@gmail.com>2012-06-15 09:11:47 +0000
commit6207cb519bbe9ce31eaef9a835fe6bd57dbf0d0f (patch)
tree865131e83bf15ff9e806b9f59b36e461808420bb /runtime
parentcd117f736c47947af5c6549734549e135e626c5c (diff)
downloadllvm-6207cb519bbe9ce31eaef9a835fe6bd57dbf0d0f.tar.gz
llvm-6207cb519bbe9ce31eaef9a835fe6bd57dbf0d0f.tar.bz2
llvm-6207cb519bbe9ce31eaef9a835fe6bd57dbf0d0f.tar.xz
Free the allocated filename. Found by clang static analyzer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158513 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'runtime')
-rw-r--r--runtime/libprofile/GCDAProfiling.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/runtime/libprofile/GCDAProfiling.c b/runtime/libprofile/GCDAProfiling.c
index b01b948142..f2dc4f7988 100644
--- a/runtime/libprofile/GCDAProfiling.c
+++ b/runtime/libprofile/GCDAProfiling.c
@@ -117,6 +117,7 @@ void llvm_gcda_start_file(const char *orig_filename) {
fprintf(stderr, "LLVM profiling runtime: cannot open '%s': ",
cptr ? cptr + 1 : orig_filename);
perror("");
+ free(filename);
return;
}
}