remove ofstream from gtk2ardour
authorRobin Gareus <robin@gareus.org>
Mon, 5 Oct 2015 19:51:52 +0000 (21:51 +0200)
committerRobin Gareus <robin@gareus.org>
Mon, 5 Oct 2015 20:15:17 +0000 (22:15 +0200)
gtk2_ardour/nag.cc

index 0dca9f84a1d8a14d0f8bb253b393c75cc7f73672..61a8e1a9a475036f839e32b42b6c8aa7266d4e24 100644 (file)
@@ -21,7 +21,7 @@
 #include "gtk2ardour-config.h"
 #endif
 
-#include <fstream>
+#include "pbd/gstdio_compat.h"
 #include <gtkmm/stock.h>
 
 #include "pbd/openuri.h"
@@ -136,7 +136,7 @@ NagScreen::mark_never_again ()
 
        path = Glib::build_filename (user_config_directory(), ".nevernag");
 
-       ofstream nagfile (path.c_str());
+       g_file_set_contents (path.c_str(), "", -1, NULL);
 }
 
 void
@@ -146,7 +146,7 @@ NagScreen::mark_subscriber ()
 
        path = Glib::build_filename (user_config_directory(), ".askedaboutsub");
 
-       ofstream subsfile (path.c_str());
+       g_file_set_contents (path.c_str(), "", -1, NULL);
 }
 
 void
@@ -156,7 +156,7 @@ NagScreen::mark_affirmed_subscriber ()
 
        path = Glib::build_filename (user_config_directory(), ".isubscribe");
 
-       ofstream subsfile (path.c_str());
+       g_file_set_contents (path.c_str(), "", -1, NULL);
 }
 
 bool