diff --git a/library/changes b/library/changes index 0528db6..3d02e0a 100644 --- a/library/changes +++ b/library/changes @@ -22,6 +22,9 @@ __translate_amiga_to_unix_path_name() to not to call strlen() on the results of __strip_double_slash(). +- For %C strtime() should return the century number, not the + year number mod 100. + c.lib 1.192 (12.5.2005) diff --git a/library/include/math.h b/library/include/math.h index 2542e8d..89225ef 100644 --- a/library/include/math.h +++ b/library/include/math.h @@ -1,5 +1,5 @@ /* - * $Id: math.h,v 1.9 2005-05-12 13:21:47 obarthel Exp $ + * $Id: math.h,v 1.10 2005-05-19 13:57:53 obarthel Exp $ * * :ts=4 * @@ -210,7 +210,7 @@ extern int __isunordered_double(double x,double y); (isunordered(x,y) ? 0 : (x) <= (y)) #define islessgreater(x,y) \ - (isunordered(x,y) ? 0 : (x) < (y) || (x) > (y)) /* ZZZ don't evaulate twice! */ + (isunordered(x,y) ? 0 : (x) < (y) || (x) > (y)) /* ZZZ don't evaluate twice! */ /****************************************************************************/ diff --git a/library/time_strftime.c b/library/time_strftime.c index 8f85140..92d44b8 100644 --- a/library/time_strftime.c +++ b/library/time_strftime.c @@ -1,5 +1,5 @@ /* - * $Id: time_strftime.c,v 1.15 2005-05-14 14:47:46 obarthel Exp $ + * $Id: time_strftime.c,v 1.16 2005-05-19 13:57:52 obarthel Exp $ * * :ts=4 * @@ -239,10 +239,10 @@ format_date(const char *format,const struct tm *tm,struct Hook * hook) format_date("%a %b %d %H:%M:%S %Y",tm,hook); break; - /* The last two digits of a year ("00"; C99). */ + /* The century number ("00"-"99"; C99). */ case 'C': - __number_to_string((unsigned int)(tm->tm_year % 100),buffer,sizeof(buffer),2); + __number_to_string((unsigned int)(tm->tm_year / 100),buffer,sizeof(buffer),2); store_string_via_hook(buffer,2,hook); break;