summaryrefslogtreecommitdiffstats
path: root/src/htags.cpp
diff options
context:
space:
mode:
authoralbert-github <albert.tests@gmail.com>2019-05-12 10:44:07 (GMT)
committeralbert-github <albert.tests@gmail.com>2019-05-12 10:44:07 (GMT)
commit192bbc4d99e468f6899d1cba4fb865c84037816a (patch)
treef7447db678e54d5ea279da4faec644e3613ea48d /src/htags.cpp
parentad9af447d77c2899c484ab9ab776667f083db64b (diff)
downloadDoxygen-192bbc4d99e468f6899d1cba4fb865c84037816a.zip
Doxygen-192bbc4d99e468f6899d1cba4fb865c84037816a.tar.gz
Doxygen-192bbc4d99e468f6899d1cba4fb865c84037816a.tar.bz2
Bug 781306 - *** Error in `doxygen': realloc(): invalid pointer: 0x0000000001d45ba0 @ exit
Crash occurs, as indicated in error report, on line 131 of htags.cpp (line.resize(len+1);) Looks like there is a buffer problem (enlarge after making the buffer smaller beforehand). The readLine should place a `\0` at the end but to be on the save side.
Diffstat (limited to 'src/htags.cpp')
-rw-r--r--src/htags.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/htags.cpp b/src/htags.cpp
index 77b1f8d..7f5870d 100644
--- a/src/htags.cpp
+++ b/src/htags.cpp
@@ -128,7 +128,7 @@ bool Htags::loadFilemap(const QCString &htmlDir)
int len;
while ((len=f.readLine(line.rawData(),maxlen))>0)
{
- line.resize(len+1);
+ line.at(len)='\0';
//printf("Read line: %s",line.data());
int sep = line.find('\t');
if (sep!=-1)