Skip to content

Commit 1e7fa54

Browse files
committed
New upstream version 3.0.6
1 parent 95546a1 commit 1e7fa54

File tree

17 files changed

+362
-30
lines changed

17 files changed

+362
-30
lines changed

ChangeLog

Lines changed: 214 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,219 @@
11
-*- coding: utf-8 -*-
22

3+
commit 23a532679b406cb53c0edfc00c91c32a5ccd335a
4+
Author: NAKAMURA Usaku <[email protected]>
5+
AuthorDate: 2023-03-30 21:41:03 +0900
6+
Commit: NAKAMURA Usaku <[email protected]>
7+
CommitDate: 2023-03-30 21:41:03 +0900
8+
9+
Fix previous commit
10+
11+
commit 4ec0bac2d9bd29541442709e6c2b62dee688c1ac
12+
Author: NAKAMURA Usaku <[email protected]>
13+
AuthorDate: 2023-03-30 20:10:01 +0900
14+
Commit: NAKAMURA Usaku <[email protected]>
15+
CommitDate: 2023-03-30 20:10:01 +0900
16+
17+
Limit header length
18+
19+
commit b427e3570d16c7b68cfa0e5e05be84ba8e3eac36
20+
Author: NAKAMURA Usaku <[email protected]>
21+
AuthorDate: 2023-03-30 19:59:19 +0900
22+
Commit: NAKAMURA Usaku <[email protected]>
23+
CommitDate: 2023-03-30 19:59:19 +0900
24+
25+
[Backport #19161] merge part of 96d1acfdf6c6b42f2029f44d5b5920961d6efa92
26+
27+
Check for TLS usability
28+
29+
On all platforms using GCC, even other than darwin.
30+
31+
commit 69f0cafa5ef6ef9c86b374531e757e885198b390
32+
Author: git <[email protected]>
33+
AuthorDate: 2023-03-30 19:49:20 +0900
34+
Commit: git <[email protected]>
35+
CommitDate: 2023-03-30 19:49:20 +0900
36+
37+
* 2023-03-30 [ci skip]
38+
39+
commit 53a7cee6850bd0d5999fcb56471f0a507222f486
40+
Author: Hiroshi SHIBATA <[email protected]>
41+
AuthorDate: 2023-03-29 13:29:08 +0900
42+
Commit: usa <[email protected]>
43+
CommitDate: 2023-03-30 19:49:08 +0900
44+
45+
Merge Time-0.1.1
46+
47+
commit 2d99ef4f74e13de352ffd867ffe7308f78d7418e
48+
Author: Hiroshi SHIBATA <[email protected]>
49+
AuthorDate: 2023-03-29 14:54:14 +0900
50+
Commit: GitHub <[email protected]>
51+
CommitDate: 2023-03-29 14:54:14 +0900
52+
53+
Merge URI-0.10.2 for Ruby 3.0 (#7607)
54+
55+
* Merge URI-0.10.2
56+
57+
* Merge URI-0.10.0.2 for bundler
58+
59+
* Added assert_linear_performance for URI tests
60+
61+
commit 57e7caeac133cc3b42031ee487e4d7a0cd2487f4
62+
Author: git <[email protected]>
63+
AuthorDate: 2023-03-29 10:58:10 +0900
64+
Commit: git <[email protected]>
65+
CommitDate: 2023-03-29 10:58:10 +0900
66+
67+
* 2023-03-29 [ci skip]
68+
69+
commit 998fe8ace4621b7337fcd88c78eec02588d0bc57
70+
Author: Nobuyoshi Nakada <[email protected]>
71+
AuthorDate: 2023-03-26 23:10:50 +0900
72+
Commit: usa <[email protected]>
73+
CommitDate: 2023-03-29 10:57:57 +0900
74+
75+
Historical timezones of Lisbon in tzdata are unstable
76+
77+
commit 4527440b5242b7e26cce2500177e989853d7fb16
78+
Author: Takashi Kokubun <[email protected]>
79+
AuthorDate: 2023-03-26 15:23:10 +0900
80+
Commit: usa <[email protected]>
81+
CommitDate: 2023-03-29 10:57:57 +0900
82+
83+
Skip test_europe_lisbon on macOS
84+
85+
until we figure out why it's failing.
86+
87+
commit 78c2e2827ef8a87da801a612b7a9418db703b2d6
88+
Author: Hiroshi SHIBATA <[email protected]>
89+
AuthorDate: 2023-02-03 15:55:33 +0900
90+
Commit: usa <[email protected]>
91+
CommitDate: 2023-03-29 10:57:57 +0900
92+
93+
Bump up CodeQL v2
94+
95+
commit 408d2dbede5da0063da0cc71007bf897991e6ca1
96+
Author: Hiroshi SHIBATA <[email protected]>
97+
AuthorDate: 2023-02-03 15:41:16 +0900
98+
Commit: usa <[email protected]>
99+
CommitDate: 2023-03-29 10:57:57 +0900
100+
101+
Skip test-bundler-prallel with macOS. It mixed system bundler path.
102+
103+
https://github.com/ruby/ruby/actions/runs/4061314416/jobs/7033111867
104+
105+
commit 57703ba1ec421c938181f49e8127c6e4ae83c281
106+
Author: Hiroshi SHIBATA <[email protected]>
107+
AuthorDate: 2023-01-06 09:58:25 +0900
108+
Commit: usa <[email protected]>
109+
CommitDate: 2023-03-29 10:57:57 +0900
110+
111+
Pin Ubuntu 20.04 because Ruby 3.0 didn't support OpenSSL 3
112+
113+
commit 6ca5d3cfed45a8c42f6dbf8126e509792576cbe1
114+
Author: Hiroshi SHIBATA <[email protected]>
115+
AuthorDate: 2023-01-06 09:36:07 +0900
116+
Commit: usa <[email protected]>
117+
CommitDate: 2023-03-29 10:57:57 +0900
118+
119+
Ruby 3.0 only supports `--jit-*` options
120+
121+
commit 9cb6b7d14571c93c5ddb4c5fbf18908b6f756b04
122+
Author: Takashi Kokubun <[email protected]>
123+
AuthorDate: 2022-11-28 06:32:39 +0900
124+
Commit: usa <[email protected]>
125+
CommitDate: 2023-03-29 10:57:57 +0900
126+
127+
Disable test-all on MJIT CI for now
128+
129+
https://github.com/ruby/ruby/actions/runs/3560006749/jobs/5979749144
130+
131+
commit 54d0a2af33c7a43ad3bc7d54da8a68d0d31e1c0a
132+
Author: 卜部昌平 <[email protected]>
133+
AuthorDate: 2021-10-22 11:15:10 +0900
134+
Commit: usa <[email protected]>
135+
CommitDate: 2023-03-29 10:57:57 +0900
136+
137+
.github: use GNUMAKEFLAGS instead of JOBS
138+
139+
A bit readable to me.
140+
See also https://github.com/ruby/ruby/pull/4880
141+
142+
commit fcab8cf702a529301568aa605774ebb470febe97
143+
Author: Takashi Kokubun <[email protected]>
144+
AuthorDate: 2022-11-28 06:12:29 +0900
145+
Commit: usa <[email protected]>
146+
CommitDate: 2023-03-29 10:57:57 +0900
147+
148+
Test only --mjit-wait for now
149+
150+
We've disabled MJIT CI on GitHub Actions for a while. It's convenient
151+
that fork repositories need to see failures or disable it.
152+
153+
We should remove unused CI by default instead of silently disabling it.
154+
Since I saw --mjit-wait passed on my fork, I'd like to try running
155+
--mjit-wait one.
156+
157+
commit d8b1279d3bf4c80ad461ed393e6e4839f3f6e1ca
158+
Author: Takashi Kokubun <[email protected]>
159+
AuthorDate: 2021-12-14 09:08:01 +0900
160+
Commit: usa <[email protected]>
161+
CommitDate: 2023-03-29 10:57:57 +0900
162+
163+
Rename --jit to --mjit (#5248)
164+
165+
* Rename --jit to --mjit
166+
167+
[Feature #18349]
168+
169+
* Fix a few more --jit references
170+
171+
* Fix MJIT Actions
172+
173+
* More s/jit/mjit/ and re-introduce --disable-jit
174+
175+
* Update NEWS.md
176+
177+
* Fix test_bug_reporter_add
178+
179+
commit f84638273a51aa56513e8f64660411151b64a4f4
180+
Author: git <[email protected]>
181+
AuthorDate: 2023-02-07 17:26:49 +0900
182+
Commit: git <[email protected]>
183+
CommitDate: 2023-02-07 17:26:49 +0900
184+
185+
* 2023-02-07 [ci skip]
186+
187+
commit 72beb9f868880a97c769d38b9aab99201300ece8
188+
Author: Nobuyoshi Nakada <[email protected]>
189+
AuthorDate: 2022-10-15 01:03:47 +0900
190+
Commit: usa <[email protected]>
191+
CommitDate: 2023-02-07 17:26:37 +0900
192+
193+
Remove wrong dollar
194+
195+
commit a0a99185577794b1915eba0dc5154f09cc95e81d
196+
Author: NAKAMURA Usaku <[email protected]>
197+
AuthorDate: 2022-12-08 12:31:20 +0900
198+
Commit: NAKAMURA Usaku <[email protected]>
199+
CommitDate: 2022-12-08 12:31:20 +0900
200+
201+
merge revision(s) 58cc3c9f: [Backport #19187]
202+
203+
[Bug #19187] Fix for tzdata-2022g
204+
205+
---
206+
test/ruby/test_time_tz.rb | 21 +++++++++++++++------
207+
1 file changed, 15 insertions(+), 6 deletions(-)
208+
209+
commit 9de654cb74daaa8918ca6b04fbce211c3ccd4209
210+
Author: NAKAMURA Usaku <[email protected]>
211+
AuthorDate: 2022-12-08 12:30:36 +0900
212+
Commit: NAKAMURA Usaku <[email protected]>
213+
CommitDate: 2022-12-08 12:30:36 +0900
214+
215+
Bump teeny
216+
3217
commit ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf
4218
Author: Kazuki Yamaguchi <[email protected]>
5219
AuthorDate: 2022-09-08 23:00:01 +0900

configure

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8980,6 +8980,41 @@ then :
89808980

89818981
fi
89828982

8983+
8984+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if thread-local storage is supported" >&5
8985+
printf %s "checking if thread-local storage is supported... " >&6; }
8986+
if test ${rb_cv_tls_supported+y}
8987+
then :
8988+
printf %s "(cached) " >&6
8989+
else $as_nop
8990+
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8991+
/* end confdefs.h. */
8992+
int __thread conftest;
8993+
int
8994+
main (void)
8995+
{
8996+
8997+
;
8998+
return 0;
8999+
}
9000+
_ACEOF
9001+
if ac_fn_c_try_link "$LINENO"
9002+
then :
9003+
rb_cv_tls_supported=yes
9004+
else $as_nop
9005+
rb_cv_tls_supported=no
9006+
fi
9007+
rm -f core conftest.err conftest.$ac_objext conftest.beam \
9008+
conftest$ac_exeext conftest.$ac_ext
9009+
fi
9010+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $rb_cv_tls_supported" >&5
9011+
colorize_result "$rb_cv_tls_supported" ; }
9012+
if test x"$rb_cv_tls_supported" != xyes
9013+
then :
9014+
printf "%s\n" "#define RB_THREAD_LOCAL_SPECIFIER_IS_UNSUPPORTED 1" >>confdefs.h
9015+
9016+
fi
9017+
89839018
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker is GNU ld" >&5
89849019
printf %s "checking whether the linker is GNU ld... " >&6; }
89859020
if test ${rb_cv_prog_gnu_ld+y}
@@ -29803,7 +29838,7 @@ then :
2980329838
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2980429839
printf "%s\n" "${msg_result_yes}yes${msg_reset}" >&6 ; }
2980529840
else $as_nop
29806-
$flag=
29841+
flag=
2980729842
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
2980829843
printf "%s\n" "${msg_result_no}no${msg_reset}" >&6 ; }
2980929844
fi

configure.ac

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,14 @@ AS_IF([test "$GCC" = yes -a "$gcc_major" -lt 3 ], [
348348
AC_MSG_ERROR([too old GCC])
349349
])
350350

351+
352+
AC_CACHE_CHECK([if thread-local storage is supported], [rb_cv_tls_supported],
353+
[AC_LINK_IFELSE([AC_LANG_PROGRAM([[int __thread conftest;]])],
354+
[rb_cv_tls_supported=yes],
355+
[rb_cv_tls_supported=no])])
356+
AS_IF([test x"$rb_cv_tls_supported" != xyes],
357+
[AC_DEFINE(RB_THREAD_LOCAL_SPECIFIER_IS_UNSUPPORTED)])
358+
351359
RUBY_PROG_GNU_LD
352360
RUBY_CPPOUTFILE
353361

@@ -2890,7 +2898,7 @@ AS_IF([test "$with_dln_a_out" != yes], [
28902898
"-undefined dynamic_lookup" \
28912899
; do
28922900
test "x${linker_flag}" = x || flag="${linker_flag}`echo ${flag} | tr ' ' ,`"
2893-
RUBY_TRY_LDFLAGS([$flag], [], [$flag=])
2901+
RUBY_TRY_LDFLAGS([$flag], [], [flag=])
28942902
AS_IF([test x"$flag" = x], [continue])
28952903
28962904
AC_MSG_CHECKING([whether $flag is accepted for bundle])

lib/bundler/vendor/uri/lib/uri/rfc3986_parser.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ module Bundler::URI
33
class RFC3986_Parser # :nodoc:
44
# Bundler::URI defined in RFC3986
55
# this regexp is modified not to host is not empty string
6-
RFC3986_URI = /\A(?<Bundler::URI>(?<scheme>[A-Za-z][+\-.0-9A-Za-z]*):(?<hier-part>\/\/(?<authority>(?:(?<userinfo>(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*)@)?(?<host>(?<IP-literal>\[(?:(?<IPv6address>(?:\h{1,4}:){6}(?<ls32>\h{1,4}:\h{1,4}|(?<IPv4address>(?<dec-octet>[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g<dec-octet>\.\g<dec-octet>\.\g<dec-octet>))|::(?:\h{1,4}:){5}\g<ls32>|\h{1,4}?::(?:\h{1,4}:){4}\g<ls32>|(?:(?:\h{1,4}:)?\h{1,4})?::(?:\h{1,4}:){3}\g<ls32>|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g<ls32>|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g<ls32>|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g<ls32>|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?<IPvFuture>v\h+\.[!$&-.0-;=A-Z_a-z~]+))\])|\g<IPv4address>|(?<reg-name>(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])+))?(?::(?<port>\d*))?)(?<path-abempty>(?:\/(?<segment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*))*)|(?<path-absolute>\/(?:(?<segment-nz>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])+)(?:\/\g<segment>)*)?)|(?<path-rootless>\g<segment-nz>(?:\/\g<segment>)*)|(?<path-empty>))(?:\?(?<query>[^#]*))?(?:\#(?<fragment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*))?)\z/
7-
RFC3986_relative_ref = /\A(?<relative-ref>(?<relative-part>\/\/(?<authority>(?:(?<userinfo>(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*)@)?(?<host>(?<IP-literal>\[(?<IPv6address>(?:\h{1,4}:){6}(?<ls32>\h{1,4}:\h{1,4}|(?<IPv4address>(?<dec-octet>[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g<dec-octet>\.\g<dec-octet>\.\g<dec-octet>))|::(?:\h{1,4}:){5}\g<ls32>|\h{1,4}?::(?:\h{1,4}:){4}\g<ls32>|(?:(?:\h{1,4}:){,1}\h{1,4})?::(?:\h{1,4}:){3}\g<ls32>|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g<ls32>|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g<ls32>|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g<ls32>|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?<IPvFuture>v\h+\.[!$&-.0-;=A-Z_a-z~]+)\])|\g<IPv4address>|(?<reg-name>(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])+))?(?::(?<port>\d*))?)(?<path-abempty>(?:\/(?<segment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*))*)|(?<path-absolute>\/(?:(?<segment-nz>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])+)(?:\/\g<segment>)*)?)|(?<path-noscheme>(?<segment-nz-nc>(?:%\h\h|[!$&-.0-9;=@-Z_a-z~])+)(?:\/\g<segment>)*)|(?<path-empty>))(?:\?(?<query>[^#]*))?(?:\#(?<fragment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*))?)\z/
6+
RFC3986_URI = /\A(?<Bundler::URI>(?<scheme>[A-Za-z][+\-.0-9A-Za-z]*+):(?<hier-part>\/\/(?<authority>(?:(?<userinfo>(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*+)@)?(?<host>(?<IP-literal>\[(?:(?<IPv6address>(?:\h{1,4}:){6}(?<ls32>\h{1,4}:\h{1,4}|(?<IPv4address>(?<dec-octet>[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g<dec-octet>\.\g<dec-octet>\.\g<dec-octet>))|::(?:\h{1,4}:){5}\g<ls32>|\h{1,4}?::(?:\h{1,4}:){4}\g<ls32>|(?:(?:\h{1,4}:)?\h{1,4})?::(?:\h{1,4}:){3}\g<ls32>|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g<ls32>|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g<ls32>|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g<ls32>|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?<IPvFuture>v\h++\.[!$&-.0-;=A-Z_a-z~]++))\])|\g<IPv4address>|(?<reg-name>(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])++))?(?::(?<port>\d*+))?)(?<path-abempty>(?:\/(?<segment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*+))*+)|(?<path-absolute>\/(?:(?<segment-nz>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])++)(?:\/\g<segment>)*+)?)|(?<path-rootless>\g<segment-nz>(?:\/\g<segment>)*+)|(?<path-empty>))(?:\?(?<query>[^#]*+))?(?:\#(?<fragment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*+))?)\z/
7+
RFC3986_relative_ref = /\A(?<relative-ref>(?<relative-part>\/\/(?<authority>(?:(?<userinfo>(?:%\h\h|[!$&-.0-;=A-Z_a-z~])*+)@)?(?<host>(?<IP-literal>\[(?:(?<IPv6address>(?:\h{1,4}:){6}(?<ls32>\h{1,4}:\h{1,4}|(?<IPv4address>(?<dec-octet>[1-9]\d|1\d{2}|2[0-4]\d|25[0-5]|\d)\.\g<dec-octet>\.\g<dec-octet>\.\g<dec-octet>))|::(?:\h{1,4}:){5}\g<ls32>|\h{1,4}?::(?:\h{1,4}:){4}\g<ls32>|(?:(?:\h{1,4}:){,1}\h{1,4})?::(?:\h{1,4}:){3}\g<ls32>|(?:(?:\h{1,4}:){,2}\h{1,4})?::(?:\h{1,4}:){2}\g<ls32>|(?:(?:\h{1,4}:){,3}\h{1,4})?::\h{1,4}:\g<ls32>|(?:(?:\h{1,4}:){,4}\h{1,4})?::\g<ls32>|(?:(?:\h{1,4}:){,5}\h{1,4})?::\h{1,4}|(?:(?:\h{1,4}:){,6}\h{1,4})?::)|(?<IPvFuture>v\h++\.[!$&-.0-;=A-Z_a-z~]++))\])|\g<IPv4address>|(?<reg-name>(?:%\h\h|[!$&-.0-9;=A-Z_a-z~])++))?(?::(?<port>\d*+))?)(?<path-abempty>(?:\/(?<segment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])*+))*+)|(?<path-absolute>\/(?:(?<segment-nz>(?:%\h\h|[!$&-.0-;=@-Z_a-z~])++)(?:\/\g<segment>)*+)?)|(?<path-noscheme>(?<segment-nz-nc>(?:%\h\h|[!$&-.0-9;=@-Z_a-z~])++)(?:\/\g<segment>)*+)|(?<path-empty>))(?:\?(?<query>[^#]*+))?(?:\#(?<fragment>(?:%\h\h|[!$&-.0-;=@-Z_a-z~\/?])*+))?)\z/
88
attr_reader :regexp
99

1010
def initialize
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module Bundler::URI
22
# :stopdoc:
3-
VERSION_CODE = '001000'.freeze
3+
VERSION_CODE = '00100002'.freeze
44
VERSION = VERSION_CODE.scan(/../).collect{|n| n.to_i}.join('.').freeze
55
# :startdoc:
66
end

lib/net/http/header.rb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
# convenient formats.
1010
#
1111
module Net::HTTPHeader
12+
MAX_KEY_LENGTH = 1024
13+
MAX_FIELD_LENGTH = 65536
1214

1315
def initialize_http_header(initheader)
1416
@header = {}
@@ -19,6 +21,12 @@ def initialize_http_header(initheader)
1921
warn "net/http: nil HTTP header: #{key}", uplevel: 3 if $VERBOSE
2022
else
2123
value = value.strip # raise error for invalid byte sequences
24+
if key.to_s.bytesize > MAX_KEY_LENGTH
25+
raise ArgumentError, "too long (#{key.bytesize} bytes) header: #{key[0, 30].inspect}..."
26+
end
27+
if value.to_s.bytesize > MAX_FIELD_LENGTH
28+
raise ArgumentError, "header #{key} has too long field vallue: #{value.bytesize}"
29+
end
2230
if value.count("\r\n") > 0
2331
raise ArgumentError, "header #{key} has field value #{value.inspect}, this cannot include CR/LF"
2432
end

lib/time.gemspec

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Gem::Specification.new do |spec|
22
spec.name = "time"
3-
spec.version = "0.1.0"
3+
spec.version = "0.1.1"
44
spec.authors = ["Tanaka Akira"]
55
spec.email = ["[email protected]"]
66

@@ -19,6 +19,4 @@ Gem::Specification.new do |spec|
1919
spec.bindir = "exe"
2020
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
2121
spec.require_paths = ["lib"]
22-
23-
spec.add_dependency "date"
2422
end

lib/time.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -506,8 +506,8 @@ def rfc2822(date)
506506
(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s+
507507
(\d{2,})\s+
508508
(\d{2})\s*
509-
:\s*(\d{2})\s*
510-
(?::\s*(\d{2}))?\s+
509+
:\s*(\d{2})
510+
(?:\s*:\s*(\d\d))?\s+
511511
([+-]\d{4}|
512512
UT|GMT|EST|EDT|CST|CDT|MST|MDT|PST|PDT|[A-IK-Z])/ix =~ date
513513
# Since RFC 2822 permit comments, the regexp has no right anchor.

0 commit comments

Comments
 (0)