From 1588d2734c8f383b459099ae56221154fb2fadc9 Mon Sep 17 00:00:00 2001 From: orignal Date: Fri, 20 Nov 2015 12:30:20 -0500 Subject: [PATCH] use path.string () instead path.c_str () --- AddressBook.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/AddressBook.cpp b/AddressBook.cpp index ed7b56ae..c06186ed 100644 --- a/AddressBook.cpp +++ b/AddressBook.cpp @@ -52,7 +52,7 @@ namespace client std::shared_ptr AddressBookFilesystemStorage::GetAddress (const i2p::data::IdentHash& ident) const { auto filename = GetPath () / (ident.ToBase32() + ".b32"); - std::ifstream f(filename.c_str (), std::ifstream::binary); + std::ifstream f(filename.string (), std::ifstream::binary); if (f.is_open ()) { f.seekg (0,std::ios::end); @@ -76,7 +76,7 @@ namespace client void AddressBookFilesystemStorage::AddAddress (std::shared_ptr address) { auto filename = GetPath () / (address->GetIdentHash ().ToBase32() + ".b32"); - std::ofstream f (filename.c_str (), std::ofstream::binary | std::ofstream::out); + std::ofstream f (filename.string (), std::ofstream::binary | std::ofstream::out); if (f.is_open ()) { size_t len = address->GetFullLen (); @@ -100,7 +100,7 @@ namespace client { int num = 0; auto filename = GetPath () / "addresses.csv"; - std::ifstream f (filename.c_str (), std::ofstream::in); // in text mode + std::ifstream f (filename.string (), std::ofstream::in); // in text mode if (f.is_open ()) { addresses.clear (); @@ -134,7 +134,7 @@ namespace client { int num = 0; auto filename = GetPath () / "addresses.csv"; - std::ofstream f (filename.c_str (), std::ofstream::out); // in text mode + std::ofstream f (filename.string (), std::ofstream::out); // in text mode if (f.is_open ()) { for (auto it: addresses)