Commits

b_michaelsen  committed fa3c952

#i105835# flushing filehandler in uieventslogger after each logged record because of buffered i/o

  • Participants
  • Parent commits 6d46b93

Comments (0)

Files changed (1)

File comphelper/source/misc/uieventslogger.cxx

     };
 }
 
-namespace comphelper 
+namespace comphelper
 {
     // consts
     const sal_Int32 UiEventsLogger_Impl::COLUMNS = 9;
             logdata[3] = URL_FILE;
         else
             logdata[3] = url.Main;
+		OSL_TRACE("UiEventsLogger Logging: %s,%s,%s,%s,%s,%s,%s,%s",
+			OUStringToOString(logdata[0],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[1],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[2],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[3],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[4],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[5],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[6],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[7],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[8],RTL_TEXTENCODING_UTF8).getStr());
         m_Logger->log(LogLevel::INFO, m_Formatter->formatMultiColumn(logdata));
+		m_LogHandler->flush();
         m_SessionLogEventCount++;
     }
 
     {
         Sequence<OUString> logdata = Sequence<OUString>(COLUMNS);
         logdata[0] = ETYPE_ROTATED;
+		OSL_TRACE("UiEventsLogger Logging: %s,%s,%s,%s,%s,%s,%s,%s",
+			OUStringToOString(logdata[0],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[1],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[2],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[3],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[4],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[5],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[6],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[7],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[8],RTL_TEXTENCODING_UTF8).getStr());
         m_Logger->log(LogLevel::INFO, m_Formatter->formatMultiColumn(logdata));
+		m_LogHandler->flush();
     }
 
     void UiEventsLogger_Impl::logVcl(
         logdata[6] = id;
         logdata[7] = method;
         logdata[8] = param;
+		OSL_TRACE("UiEventsLogger Logging: %s,%s,%s,%s,%s,%s,%s,%s",
+			OUStringToOString(logdata[0],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[1],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[2],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[3],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[4],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[5],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[6],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[7],RTL_TEXTENCODING_UTF8).getStr(),
+			OUStringToOString(logdata[8],RTL_TEXTENCODING_UTF8).getStr());
         m_Logger->log(LogLevel::INFO, m_Formatter->formatMultiColumn(logdata));
+		m_LogHandler->flush();
         m_SessionLogEventCount++;
     }