Logo Search packages:      
Sourcecode: ardour version File versions  Download package

int Glib::file_open_tmp ( std::string &  name_used  ) 

Opens a file for writing in the preferred directory for temporary files (as returned by Glib::get_tmp_dir()).

This function works like file_open_tmp(std::string&, const std::string&) but uses a default basename prefix.

Return values:
name_used The actual name used.
A file handle (as from open()) to the file opened for reading and writing. The file is opened in binary mode on platforms where there is a difference. The file handle should be closed with close().

Definition at line 161 of file fileutils.cc.

  GError* error = 0;
  ScopedPtr<char> buf_name_used;

  const int fileno = g_file_open_tmp(0, buf_name_used.addr(), &error);


  name_used = buf_name_used.get();
  return fileno;

Generated by  Doxygen 1.6.0   Back to index