Use proper logging facility, and lower the priority of some of the
logging messages. This is part of an effort to make FlightGear a bit quieter during normal operations.
This commit is contained in:
parent
906d070f68
commit
d296e5a7df
8 changed files with 11 additions and 10 deletions
|
@ -537,11 +537,11 @@ void FGATCMgr::FreqSearch(int channel) {
|
|||
FGATC* app = FindInList(comm_ident[chan], TOWER);
|
||||
if(app != NULL) {
|
||||
// The station is already in the ATC list
|
||||
cout << comm_ident[chan] << " is in list - flagging SetDisplay..." << endl;
|
||||
SG_LOG(SG_GENERAL, SG_DEBUG, comm_ident[chan] << " is in list - flagging SetDisplay...");
|
||||
app->SetDisplay();
|
||||
} else {
|
||||
// Generate the station and put in the ATC list
|
||||
cout << comm_ident[chan] << " is not in list - generating..." << endl;
|
||||
SG_LOG(SG_GENERAL, SG_DEBUG, comm_ident[chan] << " is not in list - generating...");
|
||||
FGTower* t = new FGTower;
|
||||
t->SetData(&data);
|
||||
comm_atc_ptr[chan] = t;
|
||||
|
|
|
@ -91,7 +91,7 @@ bool FGCommList::LoadComms(SGPath path) {
|
|||
ATCData a;
|
||||
fin >> a;
|
||||
if(a.type == INVALID) {
|
||||
SG_LOG(SG_GENERAL, SG_ALERT, "WARNING - INVALID type found in " << path.str() << '\n');
|
||||
SG_LOG(SG_GENERAL, SG_DEBUG, "WARNING - INVALID type found in " << path.str() << '\n');
|
||||
} else {
|
||||
// Push all stations onto frequency map
|
||||
commlist_freq[a.freq].push_back(a);
|
||||
|
|
|
@ -850,7 +850,7 @@ void NewTgtAirportInit()
|
|||
}
|
||||
|
||||
FG_FINALIZE_PUI_DIALOG( TgtAptDialog );
|
||||
printf("leave NewTgtAirportInit()");
|
||||
SG_LOG(SG_GENERAL, SG_DEBUG, "leave NewTgtAirportInit()");
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -454,7 +454,7 @@ FGInput::_init_joystick ()
|
|||
jsJoystick * js = new jsJoystick(i);
|
||||
_joystick_bindings[i].js = js;
|
||||
if (js->notWorking()) {
|
||||
SG_LOG(SG_INPUT, SG_WARN, "Joystick " << i << " not found");
|
||||
SG_LOG(SG_INPUT, SG_DEBUG, "Joystick " << i << " not found");
|
||||
continue;
|
||||
} else {
|
||||
bool found_js = false;
|
||||
|
|
|
@ -139,7 +139,7 @@ bool FGMultiplayTxMgr::init(void) {
|
|||
// If Tx port == zero then don't initialise
|
||||
} else {
|
||||
|
||||
SG_LOG( SG_NETWORK, SG_WARN, "FGMultiplayTxMgr::init - Tx Port is zero. Multiplay out disabled." );
|
||||
SG_LOG( SG_NETWORK, SG_INFO, "FGMultiplayTxMgr::init - Tx Port is zero. Multiplay out disabled." );
|
||||
bSuccess = false;
|
||||
|
||||
}
|
||||
|
@ -148,7 +148,7 @@ bool FGMultiplayTxMgr::init(void) {
|
|||
m_bInitialised = bSuccess;
|
||||
|
||||
} else {
|
||||
SG_LOG( SG_NETWORK, SG_ALERT, "FGMultiplayTxMgr::init - Attempt to init object that is already opened" );
|
||||
SG_LOG( SG_NETWORK, SG_WARN, "FGMultiplayTxMgr::init - Attempt to init object that is already opened" );
|
||||
bSuccess = false;
|
||||
}
|
||||
|
||||
|
|
|
@ -843,7 +843,7 @@ FGTileEntry::load( const string &base_path, bool is_base )
|
|||
<< " codes = " << common << " "
|
||||
<< end1 << " " << end2 );
|
||||
} else {
|
||||
SG_LOG( SG_TERRAIN, SG_ALERT,
|
||||
SG_LOG( SG_TERRAIN, SG_DEBUG,
|
||||
"Unknown token " << token << " in "
|
||||
<< stg_name.str() );
|
||||
in >> ::skipws;
|
||||
|
|
|
@ -389,6 +389,7 @@ int FGTileMgr::update( SGLocation *location, double visibility_meters,
|
|||
if ( current_tile != NULL ) {
|
||||
globals->get_scenery()->set_next_center( current_tile->center );
|
||||
} else {
|
||||
printf("Log level is %d\n", sglog().get_log_priority());
|
||||
SG_LOG( SG_TERRAIN, SG_WARN, "Tile not found (Ok if initializing)" );
|
||||
globals->get_scenery()->set_next_center( Point3D(0.0) );
|
||||
}
|
||||
|
|
|
@ -267,7 +267,7 @@ void FGElectricalSystem::init () {
|
|||
SGPath config( globals->get_fg_root() );
|
||||
config.append( path_n->getStringValue() );
|
||||
|
||||
SG_LOG( SG_ALL, SG_ALERT, "Reading electrical system model from "
|
||||
SG_LOG( SG_ALL, SG_INFO, "Reading electrical system model from "
|
||||
<< config.str() );
|
||||
try {
|
||||
readProperties( config.str(), config_props );
|
||||
|
@ -289,7 +289,7 @@ void FGElectricalSystem::init () {
|
|||
}
|
||||
|
||||
} else
|
||||
SG_LOG( SG_ALL, SG_ALERT,
|
||||
SG_LOG( SG_ALL, SG_WARN,
|
||||
"No electrical model specified for this model!");
|
||||
|
||||
delete config_props;
|
||||
|
|
Loading…
Add table
Reference in a new issue