diff options
author | Albert Astals Cid <aacid@kde.org> | 2017-03-06 22:34:20 +0100 |
---|---|---|
committer | Albert Astals Cid <aacid@kde.org> | 2017-03-06 22:34:20 +0100 |
commit | a7632c5db6875828500dce7c984ec933d5349f26 (patch) | |
tree | 88b3f1f276de189c14289723fda82c3ea0f8b42e | |
parent | 8ebec831c2abea9f13761474990c0d94346c1a35 (diff) |
pdftohtml: fix small memory leak when constructing some filenames
-rw-r--r-- | utils/HtmlOutputDev.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/utils/HtmlOutputDev.cc b/utils/HtmlOutputDev.cc index a084ba0d..5f5dc9ff 100644 --- a/utils/HtmlOutputDev.cc +++ b/utils/HtmlOutputDev.cc @@ -17,7 +17,7 @@ // All changes made under the Poppler project to this file are licensed // under GPL version 2 or later // -// Copyright (C) 2005-2013, 2016 Albert Astals Cid <aacid@kde.org> +// Copyright (C) 2005-2013, 2016, 2017 Albert Astals Cid <aacid@kde.org> // Copyright (C) 2008 Kjartan Maraas <kmaraas@gnome.org> // Copyright (C) 2008 Boris Toloknov <tlknv@yandex.ru> // Copyright (C) 2008 Haruyuki Kawabe <Haruyuki.Kawabe@unisys.co.jp> @@ -1638,7 +1638,9 @@ GooString* HtmlOutputDev::getLinkDest(AnnotLink *link){ file->append(".html"); } file->append('#'); - file->append(GooString::fromInt(page)); + GooString *pgNum = GooString::fromInt(page); + file->append(pgNum); + delete pgNum; } } if (printCommands && file) printf("filename %s\n",file->getCString()); |