Git-Url: http://git.frugalware.org/gitweb/gitweb.cgi?p=fwsetup-ng.git;a=commitdiff;h=fcb4b86dae35d4b5f1e0ff56e1e013e73c7f7cb7
commit fcb4b86dae35d4b5f1e0ff56e1e013e73c7f7cb7 Author: James Buren <[email protected]> Date: Sun Aug 19 01:05:00 2012 -0500 setup logfile in C++ diff --git a/Utility.cc b/Utility.cc index 9db576c..cb22362 100644 --- a/Utility.cc +++ b/Utility.cc @@ -9,6 +9,9 @@ #define LOGFILE "fwsetup.log" using std::stringstream; +using std::ios; + +ofstream logfile(LOGFILE,ios::app); pid_t execute(const string &cmd) { diff --git a/Utility.hh b/Utility.hh index ec9b3a8..8fc12e8 100644 --- a/Utility.hh +++ b/Utility.hh @@ -2,6 +2,7 @@ #include <sys/types.h> #include <string> +#include <fstream> #define KIBIBYTE (2LLU << 9LLU) #define MEBIBYTE (2LLU << 19LLU) @@ -9,6 +10,9 @@ #define TEBIBYTE (2LLU << 39LLU) using std::string; +using std::ofstream; + +extern ofstream logfile; pid_t execute(const string &cmd); unsigned long long string_to_size(const string &text); _______________________________________________ Frugalware-git mailing list [email protected] http://frugalware.org/mailman/listinfo/frugalware-git
