[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen master] libxc: remove usage of "daylight" variable



commit fb651884930a728e60ddd423b68a3ad38f9d0630
Author:     Roger Pau Monne <roger.pau@xxxxxxxxxx>
AuthorDate: Wed Apr 16 16:13:14 2014 +0200
Commit:     Ian Campbell <ian.campbell@xxxxxxxxxx>
CommitDate: Fri May 2 13:34:34 2014 +0100

    libxc: remove usage of "daylight" variable
    
    FreeBSD doesn't implement the XSI extension that mandates the presence
    of the daylight variable as described in:
    
    http://pubs.opengroup.org/onlinepubs/009696799/functions/tzset.html
    
    So avoid using it for portability reasons. Use tm_isdst instead to
    decide if daylight savings time conversions should be used or not.
    
    Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
    Cc: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
    Cc: Ian Campbell <ian.campbell@xxxxxxxxxx>
    Acked-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
    Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---
 tools/libxc/xtl_logger_stdio.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/libxc/xtl_logger_stdio.c b/tools/libxc/xtl_logger_stdio.c
index 47ee257..d8646e0 100644
--- a/tools/libxc/xtl_logger_stdio.c
+++ b/tools/libxc/xtl_logger_stdio.c
@@ -64,7 +64,7 @@ static void stdiostream_vmessage(xentoollog_logger *logger_in,
         fprintf(lg->f, "%04d-%02d-%02d %02d:%02d:%02d %s ",
                 lt->tm_year+1900, lt->tm_mon+1, lt->tm_mday,
                 lt->tm_hour, lt->tm_min, lt->tm_sec,
-                tzname[daylight ? !!lt->tm_isdst : 0]);
+                tzname[!!lt->tm_isdst]);
     }
     if (lg->flags & XTL_STDIOSTREAM_SHOW_PID)
         fprintf(lg->f, "[%lu] ", (unsigned long)getpid());
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.