summaryrefslogtreecommitdiff
path: root/libs/surfaces/osc/osc.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/surfaces/osc/osc.cc')
-rw-r--r--libs/surfaces/osc/osc.cc11
1 files changed, 1 insertions, 10 deletions
diff --git a/libs/surfaces/osc/osc.cc b/libs/surfaces/osc/osc.cc
index fade3b20b7..9c775121da 100644
--- a/libs/surfaces/osc/osc.cc
+++ b/libs/surfaces/osc/osc.cc
@@ -17,8 +17,6 @@
*
*/
-#include <iostream>
-#include <fstream>
#include <cstdio>
#include <cstdlib>
#include <cerrno>
@@ -208,15 +206,8 @@ OSC::start ()
std::string url_file;
if (find_file (ardour_config_search_path(), "osc_url", url_file)) {
-
_osc_url_file = url_file;
- ofstream urlfile;
- urlfile.open(_osc_url_file.c_str(), ios::trunc);
-
- if (urlfile) {
- urlfile << get_server_url () << endl;
- urlfile.close();
- } else {
+ if (g_file_set_contents (_osc_url_file.c_str(), get_server_url().c_str(), -1, NULL)) {
cerr << "Couldn't write '" << _osc_url_file << "'" <<endl;
}
}