assert_raise(Errno::ERANGE, bug4457) {Time.now.strftime('%8192z')}
end
def test_delegate
Modified time.c
diff --git a/time.c b/time.c
index dd846a6..6817c75 100644
--- a/time.c
+++ b/time.c
@@ -4325,8 +4325,12 @@ rb_strftime_alloc(char **buf, const char *format,
* if the buffer is 1024 times bigger than the length of the
* format string, it's not failing for lack of room.
*/
This issue was solved with changeset r32885.
tadayoshi, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.
time.c (rb_strftime_alloc): raise ERANGE if width is too large.
Patch by Nobuyoshi Nakada. [Bug #4457] [ruby-dev:43285]
test/ruby/test_time.rb (class TestTime): add a test for the
above change.