diff options
author | OBATA Akio <obache@wizdas.com> | 2020-07-25 11:48:24 +0900 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2021-02-02 01:42:04 +0100 |
commit | 5c32919647732d0e20dc08ad4a8d24193238174f (patch) | |
tree | e1a4aa92503ecd73a7a1bd3893df4f321ae291a1 /qmake | |
parent | 30a7754971fee794819df164dd1601b2af49587a (diff) | |
download | qt3-5c32919647732d0e20dc08ad4a8d24193238174f.tar.gz qt3-5c32919647732d0e20dc08ad4a8d24193238174f.zip |
Fix potentially buffer overrun related to readlink(2)
Signed-off-by: OBATA Akio <obache@wizdas.com>
Diffstat (limited to 'qmake')
-rw-r--r-- | qmake/project.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/qmake/project.cpp b/qmake/project.cpp index efc465d..081143c 100644 --- a/qmake/project.cpp +++ b/qmake/project.cpp @@ -724,7 +724,7 @@ QMakeProject::isActiveConfig(const QString &x, bool regex, QMap<QString, QString static char *buffer = NULL; if(!buffer) buffer = (char *)malloc(1024); - int l = readlink(Option::mkfile::qmakespec, buffer, 1024); + int l = readlink(Option::mkfile::qmakespec, buffer, 1023); if(l != -1) { buffer[l] = '\0'; QString r = buffer; |