ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/repos/Spectre2/Mounter.cpp
(Generate patch)

Comparing Spectre2/Mounter.cpp (file contents):
Revision 433 by douglas, 2005-03-29T13:43:22-08:00 vs.
Revision 439 by douglas, 2005-04-07T15:56:53-07:00

# Line 33 | Line 33 | void Mounter::operator()()
33  
34                  if (!password) _synchronized (Daemon::secretLock)
35                  {
36 <                        AppendFileWriter out(Daemon::secret);
36 >                        api::FileWriter out(Daemon::secret, O_WRONLY | O_APPEND, 0);
37                          ios::FormatWriter fout(out);
38  
39                          fout << "[" << share.getHost() << ":" << share.getOwner() << "]" << ios::NewLine << "password=" << share.getPassword() << ios::NewLine;
# Line 51 | Line 51 | void Mounter::operator()()
51                  credentials << "/tmp/.spectre" << api::Uuid::Create();
52  
53                  {
54 <                        SecretFileWriter out(credentials);
54 >                        api::FileWriter out(credentials, O_WRONLY | O_CREAT | O_TRUNC, 0600);
55                          ios::FormatWriter fout(out);
56  
57                          fout << "username = " << share.getOwner() << ios::NewLine << "password = " << share.getPassword() << ios::NewLine;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines