summaryrefslogtreecommitdiffstats
path: root/Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx
diff options
context:
space:
mode:
authorKyle Edwards <kyle.edwards@kitware.com>2021-06-07 19:35:12 (GMT)
committerKyle Edwards <kyle.edwards@kitware.com>2021-06-07 19:35:48 (GMT)
commit100d3cb392679f2531ede8e3f3e944b13124cfda (patch)
tree6e408641e191e51a46b4cf0492109f74a30cac4a /Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx
parent8732749ef48eac78036f3bf28432223105e94f3e (diff)
downloadCMake-100d3cb392679f2531ede8e3f3e944b13124cfda.zip
CMake-100d3cb392679f2531ede8e3f3e944b13124cfda.tar.gz
CMake-100d3cb392679f2531ede8e3f3e944b13124cfda.tar.bz2
file(GET_RUNTIME_DEPENDENCIES): Use cmSystemTools::GetLineFromStream()
Fixes: #22278
Diffstat (limited to 'Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx')
-rw-r--r--Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx b/Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx
index 1effda0..f14de55 100644
--- a/Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx
+++ b/Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx
@@ -8,6 +8,7 @@
#include <cmsys/RegularExpression.hxx>
#include "cmRuntimeDependencyArchive.h"
+#include "cmSystemTools.h"
#include "cmUVProcessChain.h"
cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool::
@@ -42,8 +43,8 @@ bool cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool::GetFileInfo(
std::string line;
static const cmsys::RegularExpression regex(
- "^\t*DLL Name: ([^\n]*\\.[Dd][Ll][Ll])\r$");
- while (std::getline(*process.OutputStream(), line)) {
+ "^\t*DLL Name: ([^\n]*\\.[Dd][Ll][Ll])$");
+ while (cmSystemTools::GetLineFromStream(*process.OutputStream(), line)) {
cmsys::RegularExpressionMatch match;
if (regex.find(line.c_str(), match)) {
needed.push_back(match.match(1));