The main posixpp library and associated tests.
Revision | 61484b250fd1be0b2795d56cd3bbb0129d390815 (tree) |
---|---|
Time | 2021-04-28 21:51:39 |
Author | Eric Hopper <hopper@omni...> |
Commiter | Eric Hopper |
Fix to use .native() instead of .string() to get filenames.
@@ -21,7 +21,7 @@ | ||
21 | 21 | using ::posixpp::modeflags; |
22 | 22 | auto foo{ |
23 | 23 | fd::open( |
24 | - fooname.string().c_str(), | |
24 | + fooname.native().c_str(), | |
25 | 25 | of::creat | fdf::wronly, |
26 | 26 | modeflags::irwall |
27 | 27 | ).result() |
@@ -34,7 +34,7 @@ | ||
34 | 34 | "The C access call shows the file " |
35 | 35 | "existing and being readable and writable" |
36 | 36 | ) { |
37 | - REQUIRE(::access(fooname.string().c_str(), R_OK | W_OK) == 0); | |
37 | + REQUIRE(::access(fooname.native().c_str(), R_OK | W_OK) == 0); | |
38 | 38 | } |
39 | 39 | AND_GIVEN( |
40 | 40 | "a small, constant sized message and a small similarly " |
@@ -55,7 +55,7 @@ | ||
55 | 55 | REQUIRE_FALSE(close_result.has_error()); |
56 | 56 | REQUIRE_FALSE(foo.is_valid()); |
57 | 57 | |
58 | - foo = fd::open(fooname.string().c_str(), fdf::rdonly).result(); | |
58 | + foo = fd::open(fooname.native().c_str(), fdf::rdonly).result(); | |
59 | 59 | REQUIRE(foo.is_valid()); |
60 | 60 | |
61 | 61 | // Try to read more than was written to make sure we can't read |