aboutsummaryrefslogtreecommitdiff
path: root/tests/fdstream/driver.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'tests/fdstream/driver.cxx')
-rw-r--r--tests/fdstream/driver.cxx3
1 files changed, 1 insertions, 2 deletions
diff --git a/tests/fdstream/driver.cxx b/tests/fdstream/driver.cxx
index c8748b1..41a39b0 100644
--- a/tests/fdstream/driver.cxx
+++ b/tests/fdstream/driver.cxx
@@ -37,8 +37,7 @@ static const string text3 ("ABCDEF\r\nXYZ");
static string
from_stream (ifdstream& is)
{
- string s;
- getline (is, s, '\0');
+ string s (is.read_text ());
is.close (); // Not to miss failed close of the underlying file descriptor.
return s;
}