simgear/debug/logstream.cxx: Fixed FileLogCallback to not output <filename>:-1.
logstream::LogStreamPrivate::log() sets line=-1 to turn off both filename and line numbers in log output, if m_fileLine is false. StderrLogCallback::operator() already omits both file and line if line == -1; this commit does the same thing for FileLogCallback::operator(). E.g. this fixes output e.g. to ~/.fgfs/fgfs.log.
This commit is contained in:
parent
ba7134c2a2
commit
e78205f071
@ -158,11 +158,16 @@ public:
|
||||
<< std::setw(10)
|
||||
<< std::left
|
||||
<< debugClassToString(c)
|
||||
<< " "
|
||||
;
|
||||
if (file && line != -1) {
|
||||
m_file
|
||||
<< file
|
||||
<< ":"
|
||||
<< line
|
||||
<< ": "
|
||||
;
|
||||
}
|
||||
m_file
|
||||
<< message << std::endl;
|
||||
//m_file << debugClassToString(c) << ":" << (int)p
|
||||
// << ":" << file << ":" << line << ":" << message << std::endl;
|
||||
|
Loading…
Reference in New Issue
Block a user