From 100d3cb392679f2531ede8e3f3e944b13124cfda Mon Sep 17 00:00:00 2001 From: Kyle Edwards Date: Mon, 7 Jun 2021 15:35:12 -0400 Subject: file(GET_RUNTIME_DEPENDENCIES): Use cmSystemTools::GetLineFromStream() Fixes: #22278 --- Source/cmBinUtilsWindowsPEObjdumpGetRuntimeDependenciesTool.cxx | 5 +++-- 1 file 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 #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)); -- cgit v0.12