diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-07-22 10:55:22 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-07-22 10:55:22 +0000 |
commit | cf35eb556d2b7c595b6f2492609f224426d455de (patch) | |
tree | e88ef2d5418fd5a62883163d50961d2dd84626ec /vm.c | |
parent | b2da46094d7dc6a6a257693e3a85fb7949e68573 (diff) | |
download | ruby-cf35eb556d2b7c595b6f2492609f224426d455de.tar.gz |
Fix Issues reported by PVS-Studio static analyzer
* vm.c (vm_set_main_stack): remove unnecessary check. toplevel
binding must be initialized. [Bug #12611] (N1)
* win32/win32.c (w32_symlink): fix return type. [Bug #12611] (N3)
* string.c (rb_str_split_m): simplify the condition.
[Bug #12611](N4)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm.c')
-rw-r--r-- | vm.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -379,7 +379,7 @@ vm_set_main_stack(rb_thread_t *th, const rb_iseq_t *iseq) vm_set_eval_stack(th, iseq, 0, &env->block); /* save binding */ - if (bind && iseq->body->local_size > 0) { + if (iseq->body->local_size > 0) { bind->env = vm_make_env_object(th, th->cfp); } } |