From 1d51748034c6f3d6f87a18ec74f785abcc1c1c74 Mon Sep 17 00:00:00 2001 From: hniksic <devnull@localhost> Date: Tue, 3 Apr 2001 11:54:32 -0700 Subject: [PATCH] [svn] Fix support for rfc850 time recognition on systems where strptime format specs %a and %A are not the same. Published in <49022.983849922@ideon.st.ryukoku.ac.jp>. --- src/ChangeLog | 5 +++++ src/http.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 83a58380..6fcd4f97 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2001-04-03 KOJIMA Hajime <kjm@rins.ryukoku.ac.jp> + + * http.c (http_atotm): Use %A instead of %a to match full + weekday. (On most systems there is no difference.) + 2001-04-03 Paul Bludov <paul@ozero.net> * mswindows.c (sleep): Use SleepEx() instead of Sleep(). diff --git a/src/http.c b/src/http.c index 7c40d060..ec593be2 100644 --- a/src/http.c +++ b/src/http.c @@ -1898,8 +1898,8 @@ http_atotm (char *time_string) /* RFC1123: Thu, 29 Jan 1998 22:12:57 */ if (check_end (strptime (time_string, "%a, %d %b %Y %T", &t))) return mktime_from_utc (&t); - /* RFC850: Thu, 29-Jan-98 22:12:57 */ - if (check_end (strptime (time_string, "%a, %d-%b-%y %T", &t))) + /* RFC850: Thursday, 29-Jan-98 22:12:57 */ + if (check_end (strptime (time_string, "%A, %d-%b-%y %T", &t))) return mktime_from_utc (&t); /* asctime: Thu Jan 29 22:12:57 1998 */ if (check_end (strptime (time_string, "%a %b %d %T %Y", &t)))