From ed85a819a286e155980b9a3c56cfc15f9e12f64b Mon Sep 17 00:00:00 2001 From: glywk Date: Fri, 25 Oct 2024 10:19:56 +0200 Subject: [PATCH] [AVRO-4084][C++] Fix bad filesystem::path conversion type on windows (#3220) Co-authored-by: blissful --- lang/c++/test/CommonsSchemasTests.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lang/c++/test/CommonsSchemasTests.cc b/lang/c++/test/CommonsSchemasTests.cc index 84ee74928be..e29c0b4ac8b 100644 --- a/lang/c++/test/CommonsSchemasTests.cc +++ b/lang/c++/test/CommonsSchemasTests.cc @@ -41,8 +41,8 @@ void testCommonSchema(const std::filesystem::path &dir_path) { GenericDatum datum(schema); const std::filesystem::path &outputDataFile = dir_path / "data_out.avro"; - DataFileReader reader(dataFile.c_str()); - DataFileWriter writer(outputDataFile.c_str(), schema); + DataFileReader reader(dataFile.string().c_str()); + DataFileWriter writer(outputDataFile.string().c_str(), schema); while (reader.read(datum)) { datum.value(); @@ -54,8 +54,8 @@ void testCommonSchema(const std::filesystem::path &dir_path) { GenericDatum datumOrig(schema); GenericDatum datumNew(schema); - DataFileReader readerOrig(dataFile.c_str()); - DataFileReader readerNew(outputDataFile.c_str()); + DataFileReader readerOrig(dataFile.string().c_str()); + DataFileReader readerNew(outputDataFile.string().c_str()); while (readerOrig.read(datumOrig)) { BOOST_CHECK(readerNew.read(datumNew)); avro::GenericRecord &rec1 = datumOrig.value();