Ignore:
Timestamp:
03/23/12 22:08:54 (13 years ago)
Author:
tbretz
Message:
Implemented fVerbose to switch verbosity of default messages on and off.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/Connection.cc

    r13200 r13209  
    8989void Connection::CloseImp(bool restart)
    9090{
    91     if (IsConnected())
     91    if (IsConnected() && fVerbose)
    9292    {
    9393        ostringstream str;
     
    303303        setsockopt(native(), SOL_TCP, TCP_KEEPINTVL, &optval, sizeof(optval));
    304304
    305         Info("Connection established to "+host+"...");
     305        if (fVerbose)
     306            Info("Connection established to "+host+"...");
    306307
    307308        fConnectionStatus = kConnected;
     
    416417    {
    417418        fMsgConnect = msg.str();
    418         ec ? Error(msg) : Info(msg);
     419        if (ec)
     420            Error(msg);
     421        if (!ec && fVerbose)
     422            Info(msg);
    419423    }
    420424
     
    474478
    475479Connection::Connection(ba::io_service& ioservice, ostream &out) :
    476 MessageImp(out), tcp::socket(ioservice), fLog(0),
     480MessageImp(out), tcp::socket(ioservice), fLog(0), fVerbose(true),
    477481fInTimeout(ioservice), fOutTimeout(ioservice), fConnectionTimer(ioservice),
    478482fConnectionStatus(kDisconnected)
Note: See TracChangeset for help on using the changeset viewer.