Skip to content

Commit 81501ed

Browse files
committed
remove carriage returns when comparing strings for tests
1 parent 70de947 commit 81501ed

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/pdal/test/Support.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,10 @@ uint32_t Support::diff_text_files(std::istream& str1, std::istream& str2,
136136
std::getline(str1, buf1);
137137
std::getline(str2, buf2);
138138

139+
// Remove \r's
140+
buf1.erase( std::remove(buf1.begin(), buf1.end(), '\r'), buf1.end() );
141+
buf1.erase( std::remove(buf2.begin(), buf2.end(), '\r'), buf2.end() );
142+
139143
if (currLine == ignoreLine1)
140144
{
141145
++currLine;

0 commit comments

Comments
 (0)