ruby-changes:49913
From: normal <ko1@a...>
Date: Thu, 25 Jan 2018 07:40:07 +0900 (JST)
Subject: [ruby-changes:49913] normal:r62031 (trunk): vm.c: remove unnecessary branch
normal 2018-01-25 07:40:01 +0900 (Thu, 25 Jan 2018) New Revision: 62031 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=62031 Log: vm.c: remove unnecessary branch th->altstack is never NULL, and even if it were, POSIX stipulates free(3) on NULL to be a no-op. Modified files: trunk/vm.c Index: vm.c =================================================================== --- vm.c (revision 62030) +++ vm.c (revision 62031) @@ -2439,9 +2439,7 @@ thread_free(void *ptr) https://github.com/ruby/ruby/blob/trunk/vm.c#L2439 } else { #ifdef USE_SIGALTSTACK - if (th->altstack) { - free(th->altstack); - } + free(th->altstack); #endif ruby_xfree(ptr); } -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/