aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2019-08-12 17:01:27 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2019-08-12 17:01:27 +0200
commit886b47188a589968f5c566ec20d560554105a704 (patch)
treed17b63a3859fe4019df6f54c384b4f4dfb5f00bf
parent67097bb095819072579994595a2e2cb6e0cd9600 (diff)
Fix fdstream usage
-rw-r--r--bdep/new.cxx8
1 files changed, 6 insertions, 2 deletions
diff --git a/bdep/new.cxx b/bdep/new.cxx
index f9a3c82..1aebc57 100644
--- a/bdep/new.cxx
+++ b/bdep/new.cxx
@@ -714,7 +714,9 @@ namespace bdep
{
try
{
- os.open (f, fdopen_mode::create | fdopen_mode::exclusive);
+ os.open (f, (fdopen_mode::out |
+ fdopen_mode::create |
+ fdopen_mode::exclusive));
cf = f;
rms.push_back (auto_rmfile (move (f)));
}
@@ -1980,7 +1982,9 @@ namespace bdep
bool e (exists (f));
try
{
- ofdstream os (f, fdopen_mode::create | fdopen_mode::append);
+ ofdstream os (f, (fdopen_mode::out |
+ fdopen_mode::create |
+ fdopen_mode::append));
os << (e ? ":" : ": 1") << endl
<< "location: " << pkg->posix_representation () << endl;
os.close ();