posix: prefer char strings for the time being

This commit is contained in:
Danny Robson 2019-05-04 11:33:43 +10:00
parent a03bdf5e1d
commit 577d7f5887
2 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@ using cruft::posix::dir;
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
dir::dir (const std::filesystem::path &p): dir::dir (const std::filesystem::path &p):
m_handle (::opendir (p.u8string ().c_str ())) m_handle (::opendir (p.string<char> ().c_str ()))
{ {
if (!m_handle) if (!m_handle)
error::throw_code (); error::throw_code ();

View File

@ -26,7 +26,7 @@ fd::fd (const std::filesystem::path &path, int flags):
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
fd::fd (const std::filesystem::path &path, int flags, mode_t mode): fd::fd (const std::filesystem::path &path, int flags, mode_t mode):
m_fd (error::try_value (::open (path.u8string ().c_str (), flags, mode))) m_fd (error::try_value (::open (path.string<char> ().c_str (), flags, mode)))
{ {
// You always want binary mode. Always. // You always want binary mode. Always.
// //