* process.c (security): always give warning for insecure PATH.

* dir.c (my_getcwd): do not rely on MAXPATHLEN.

* file.c (rb_file_s_readlink): ditto.

* file.c (path_check_1): ditto.

* eval.c (rb_yield_0): should not call rb_f_block_given_p().

* string.c (rb_str_chomp_bang): should terminate string by NUL.

* eval.c (rb_yield_0): better error message.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1816 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 2001-11-08 06:43:14 +00:00
parent ab827130d3
commit dc98adf839
17 changed files with 201 additions and 109 deletions

4
eval.c
View file

@ -3645,8 +3645,8 @@ rb_yield_0(val, self, klass, pcall)
int state;
static unsigned serial = 1;
if (!(rb_block_given_p() || rb_f_block_given_p())) {
rb_raise(rb_eLocalJumpError, "yield called out of block");
if (!rb_block_given_p()) {
rb_raise(rb_eLocalJumpError, "no block given");
}
PUSH_VARS();