OMNeT++/OMNEST Bug Tracker - OMNeT++
View Issue Details
0000327OMNeT++simulation kernelpublic2011-05-31 17:052011-05-31 17:05
jesjones 
 
normalminoralways
newopen 
4.1 
 
0000327: Use stderr with undisposedObject
It's helpful to report errors using stderr instead of stdout (e.g. we run simulations using a custom app which colors errors in red making them much more visible).
@@ -1325,17 +1325,17 @@ void EnvirBase::sputn(const char *s, int n)
 {
     if (record_eventlog)
         eventlogmgr->sputn(s, n);
 }
 
 void EnvirBase::undisposedObject(cObject *obj)
 {
     if (opt_print_undisposed)
- ::printf("undisposed object: (%s) %s -- check module destructor\n", obj->getClassName(), obj->getFullPath().c_str());
+ ::fprintf(stderr, "undisposed object: (%s) %s -- check module destructor\n", obj->getClassName(), obj->getFullPath().c_str());
 }
 
 //-------------------------------------------------------------
 
 void EnvirBase::processFileName(opp_string& fname)
 {
     std::string text = fname.c_str();
 
No tags attached.
Issue History
2011-05-31 17:05jesjonesNew Issue

There are no notes attached to this issue.