ruby-changes:17850
From: shyouhei <ko1@a...>
Date: Mon, 22 Nov 2010 16:32:13 +0900 (JST)
Subject: [ruby-changes:17850] Ruby:r29863 (ruby_1_8_7): Sun, 3 Oct 2010 09:30:30 +0000 nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>
shyouhei 2010-11-22 16:22:12 +0900 (Mon, 22 Nov 2010) New Revision: 29863 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=29863 Log: Sun, 3 Oct 2010 09:30:30 +0000 nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> merge revision(s) 29396: * parse.y (rb_intern): should check symbol table overflow. #3900 [ruby-dev:42330] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@29396 b2dd03c8-39d4-4d8f-98ff-823fe69b080e Signed-off-by: URABE, Shyouhei <shyouhei@r...> Modified files: branches/ruby_1_8_7/ChangeLog branches/ruby_1_8_7/parse.y branches/ruby_1_8_7/version.h Index: ruby_1_8_7/parse.y =================================================================== --- ruby_1_8_7/parse.y (revision 29862) +++ ruby_1_8_7/parse.y (revision 29863) @@ -6222,6 +6222,16 @@ } if (*m) id = ID_JUNK; new_id: + if (last_id >= SYM2ID(~(VALUE)0) >> ID_SCOPE_SHIFT) { + if (last > 20) { + rb_raise(rb_eRuntimeError, "symbol table overflow (symbol %.20s...)", + name); + } + else { + rb_raise(rb_eRuntimeError, "symbol table overflow (symbol %.*s)", + last, name); + } + } id |= ++last_id << ID_SCOPE_SHIFT; id_regist: name = strdup(name); Index: ruby_1_8_7/ChangeLog =================================================================== --- ruby_1_8_7/ChangeLog (revision 29862) +++ ruby_1_8_7/ChangeLog (revision 29863) @@ -1,3 +1,8 @@ +Sun Oct 3 18:30:23 2010 Nobuyoshi Nakada <nobu@r...> + + * parse.y (rb_intern): should check symbol table overflow. + #3900 [ruby-dev:42330] + Fri Oct 1 15:12:05 2010 NAKAMURA Usaku <usa@r...> * win32/win32.c (init_stdhandle): redirect unopened IOs to NUL. Index: ruby_1_8_7/version.h =================================================================== --- ruby_1_8_7/version.h (revision 29862) +++ ruby_1_8_7/version.h (revision 29863) @@ -2,7 +2,7 @@ #define RUBY_RELEASE_DATE "2010-11-22" #define RUBY_VERSION_CODE 187 #define RUBY_RELEASE_CODE 20101122 -#define RUBY_PATCHLEVEL 312 +#define RUBY_PATCHLEVEL 313 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/