diff options
author | Michael Vogt <mvo@debian.org> | 2014-05-27 23:42:10 +0200 |
---|---|---|
committer | Michael Vogt <mvo@debian.org> | 2014-05-27 23:42:10 +0200 |
commit | 7f48c4dfbb1f27c51044edde0692d7446ee74438 (patch) | |
tree | 0628af9528406033160984ab7ff3fc0fdea4a99a /apt-pkg/deb | |
parent | de6221c9d5f99a276628bcf45fb28537e46e7660 (diff) |
use free() instead of delete[] in debSrcRecordParser::~debSrcRecordParser
The Buffer was allocated using strndup() so we need to free it using
free() instead of delete[]
Diffstat (limited to 'apt-pkg/deb')
-rw-r--r-- | apt-pkg/deb/debsrcrecords.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/apt-pkg/deb/debsrcrecords.cc b/apt-pkg/deb/debsrcrecords.cc index b09588dd3..a444cbe4d 100644 --- a/apt-pkg/deb/debsrcrecords.cc +++ b/apt-pkg/deb/debsrcrecords.cc @@ -186,6 +186,7 @@ bool debSrcRecordParser::Files(std::vector<pkgSrcRecords::File> &List) /* */ debSrcRecordParser::~debSrcRecordParser() { - delete[] Buffer; + // was allocated via strndup() + free(Buffer); } /*}}}*/ |