[ 
https://issues.apache.org/jira/browse/LOG4NET-412?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14390021#comment-14390021
 ] 

Son Tran commented on LOG4NET-412:
----------------------------------

Above code hang when run out of battery.
so I use simple wrap of Environment.TickCount like this
public static DateTimeCF
{
private static DateTime m_start = DateTime.Now;
private static m_startTickCount = Environment.TickCount;

public static DateTime Now
{
      return m_start.AddMilliseconds(Environment.TickCount - m_startTickCount);
}

}

and I change in LoggingEvent to

#if !NETCF
            m_data.TimeStamp = DateTime.Now;
#else
            m_data.TimeStamp = DateTimeCF.Now;
#endif


> Millisecond always return 0 in wince 
> -------------------------------------
>
>                 Key: LOG4NET-412
>                 URL: https://issues.apache.org/jira/browse/LOG4NET-412
>             Project: Log4net
>          Issue Type: Bug
>          Components: Appenders
>    Affects Versions: 1.3.0
>         Environment: NETCF
>            Reporter: Son Tran
>            Priority: Trivial
>              Labels: DateTime,
>
> As I check the DateTime.Ticks is used in function 
> AbsoluteTimeDateFormatter.FormatDate always return 0
> work around by using Enviroment.TichCount.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to