Only set tm_gmtoff and tm_zone fields if __USE_BSD is defined
2001-09-28 Bradford Hovinen <hovinen@ximian.com> * config-log.c (parse_line): Only set tm_gmtoff and tm_zone fields if __USE_BSD is defined * util.c (parse_date): Ditto
This commit is contained in:
parent
c01fe3b0ac
commit
091dc3447c
3 changed files with 9 additions and 0 deletions
|
@ -1,5 +1,10 @@
|
||||||
2001-09-28 Bradford Hovinen <hovinen@ximian.com>
|
2001-09-28 Bradford Hovinen <hovinen@ximian.com>
|
||||||
|
|
||||||
|
* config-log.c (parse_line): Only set tm_gmtoff and tm_zone fields
|
||||||
|
if __USE_BSD is defined
|
||||||
|
|
||||||
|
* util.c (parse_date): Ditto
|
||||||
|
|
||||||
* bonobo-config-archiver.c (bonobo_config_archiver_new): Store the
|
* bonobo-config-archiver.c (bonobo_config_archiver_new): Store the
|
||||||
listener id in the archiver_db structure
|
listener id in the archiver_db structure
|
||||||
(bonobo_config_archiver_destroy): Remove the event source
|
(bonobo_config_archiver_destroy): Remove the event source
|
||||||
|
|
|
@ -824,8 +824,10 @@ parse_line (char *buffer, int *id, struct tm *date, char **backend_id)
|
||||||
if (extract_number (&buffer, &date->tm_sec, 2) == FALSE)
|
if (extract_number (&buffer, &date->tm_sec, 2) == FALSE)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
#ifdef __USE_BSD
|
||||||
date->tm_gmtoff = 0;
|
date->tm_gmtoff = 0;
|
||||||
date->tm_zone = "GMT";
|
date->tm_zone = "GMT";
|
||||||
|
#endif
|
||||||
|
|
||||||
if (!isspace (*buffer) || *(buffer + 1) == '\0') return FALSE;
|
if (!isspace (*buffer) || *(buffer + 1) == '\0') return FALSE;
|
||||||
buffer++;
|
buffer++;
|
||||||
|
|
|
@ -94,8 +94,10 @@ parse_date (char *str)
|
||||||
if (extract_number (&str, &value, 2))
|
if (extract_number (&str, &value, 2))
|
||||||
date->tm_sec = value;
|
date->tm_sec = value;
|
||||||
|
|
||||||
|
#ifdef __USE_BSD
|
||||||
date->tm_zone = "GMT";
|
date->tm_zone = "GMT";
|
||||||
date->tm_gmtoff = 0;
|
date->tm_gmtoff = 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
return date;
|
return date;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue