From: arjen Date: Wed, 3 Dec 2003 08:23:17 +0000 (+0000) Subject: Write messages to the log stream instead of cout. X-Git-Tag: V0_0_9~17 X-Git-Url: http://www.andromeda.nl/gitweb/?p=gnucomo.git;a=commitdiff_plain;h=6b07f690595c2eedba5f2c8b850a177ea35e3a3e Write messages to the log stream instead of cout. --- diff --git a/src/lib/database.cpp b/src/lib/database.cpp index 2b073e7..36d461c 100644 --- a/src/lib/database.cpp +++ b/src/lib/database.cpp @@ -8,7 +8,7 @@ *********************** ** FILE NAME : database.cpp ** SYSTEM NAME : Gnucomo - Gnu Computer Monitoring -** VERSION NUMBER : $Revision: 1.9 $ +** VERSION NUMBER : $Revision: 1.10 $ ** ** DESCRIPTION : Implementation of the gnucomo database classes ** @@ -26,7 +26,10 @@ /***************************** $Log: database.cpp,v $ - Revision 1.9 2003-08-17 11:39:56 arjen + Revision 1.10 2003-12-03 08:23:17 arjen + Write messages to the log stream instead of cout. + + Revision 1.9 2003/08/17 11:39:56 arjen Changed the gnucomo_database class to the new PostgreSQL library, libpqxx @@ -58,12 +61,14 @@ *****************************/ -static const char *RCSID = "$Id: database.cpp,v 1.9 2003-08-17 11:39:56 arjen Exp $"; +static const char *RCSID = "$Id: database.cpp,v 1.10 2003-12-03 08:23:17 arjen Exp $"; #include #include "database.h" +extern std::ostream *log; + /*========================================================================= ** NAME : gnucomo_database ** SYNOPSIS : gnucomo_database(gnucomo_config &c); @@ -184,7 +189,7 @@ String gnucomo_database::new_notification(String objectid, String issue, String String issueid(""); - std::cout << "Creating notification for " << issue << ": " << remark << "\n"; + *log << "Creating notification for " << issue << ": " << remark << "\n"; qry = "select type_of_issueid, suggested_priority from type_of_issue where name='"; qry += issue + "'";