Commit b8244883 authored by unknown's avatar unknown

BUG#22310 dead/deceptive code in FileLogHandler::writeFooter() and File_class::flush

make the File_class::flush() method actually flush the stdio buffers.


ndb/src/common/logger/FileLogHandler.cpp:
  remove misleading comment
ndb/src/common/util/File.cpp:
  actually flush the stdio buffers.
  
  remove unneeded // private comment
parent e2ea6f70
...@@ -125,8 +125,6 @@ FileLogHandler::writeFooter() ...@@ -125,8 +125,6 @@ FileLogHandler::writeFooter()
} }
callCount++; callCount++;
// Needed on Cello since writes to the flash disk does not happen until
// we flush and fsync.
m_pLogFile->flush(); m_pLogFile->flush();
} }
......
...@@ -188,10 +188,6 @@ File_class::flush() const ...@@ -188,10 +188,6 @@ File_class::flush() const
::fflush(m_file); ::fflush(m_file);
return ::fsync(::fileno(m_file)); return ::fsync(::fileno(m_file));
#else #else
return 0; return ::fflush(m_file);;
#endif #endif
} }
//
// PRIVATE
//
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment