Author: dpsenner Date: Thu Jun 20 07:33:09 2013 New Revision: 1494880 URL: http://svn.apache.org/r1494880 Log: LOG4NET-382 fixed initialization order of static readonly fields
Modified: logging/log4net/trunk/src/Appender/EventLogAppender.cs Modified: logging/log4net/trunk/src/Appender/EventLogAppender.cs URL: http://svn.apache.org/viewvc/logging/log4net/trunk/src/Appender/EventLogAppender.cs?rev=1494880&r1=1494879&r2=1494880&view=diff ============================================================================== --- logging/log4net/trunk/src/Appender/EventLogAppender.cs (original) +++ logging/log4net/trunk/src/Appender/EventLogAppender.cs Thu Jun 20 07:33:09 2013 @@ -615,17 +615,6 @@ namespace log4net.Appender private readonly static Type declaringType = typeof(EventLogAppender); /// <summary> - /// The maximum size that the operating system supports for - /// a event log message. - /// </summary> - /// <remarks> - /// Used to determine the maximum string length that can be written - /// to the operating system event log and eventually truncate a string - /// that exceeds the limits. - /// </remarks> - private readonly static int MAX_EVENTLOG_MESSAGE_SIZE = GetMaxEventLogMessageSize(); - - /// <summary> /// The maximum size supported by default. /// </summary> /// <remarks> @@ -671,6 +660,17 @@ namespace log4net.Appender private readonly static int MAX_EVENTLOG_MESSAGE_SIZE_VISTA_OR_NEWER = 31839 - 2; /// <summary> + /// The maximum size that the operating system supports for + /// a event log message. + /// </summary> + /// <remarks> + /// Used to determine the maximum string length that can be written + /// to the operating system event log and eventually truncate a string + /// that exceeds the limits. + /// </remarks> + private readonly static int MAX_EVENTLOG_MESSAGE_SIZE = GetMaxEventLogMessageSize(); + + /// <summary> /// This method determines the maximum event log message size allowed for /// the current environment. /// </summary>