ruby-changes:53565
From: normal <ko1@a...>
Date: Sun, 18 Nov 2018 13:34:57 +0900 (JST)
Subject: [ruby-changes:53565] normal:r65781 (trunk): vm_trace.c (rb_postponed_job_flush): use rb_atomic_t for mask
normal 2018-11-18 13:34:52 +0900 (Sun, 18 Nov 2018) New Revision: 65781 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=65781 Log: vm_trace.c (rb_postponed_job_flush): use rb_atomic_t for mask ec->interrupt_mask will remain rb_atomic_t and is 32-bit on some 64-bit systems while "unsigned long" is 64-bits. So avoid mismatching lengths and stick to rb_atomic_t. Modified files: trunk/vm_trace.c Index: vm_trace.c =================================================================== --- vm_trace.c (revision 65780) +++ vm_trace.c (revision 65781) @@ -1665,8 +1665,8 @@ void https://github.com/ruby/ruby/blob/trunk/vm_trace.c#L1665 rb_postponed_job_flush(rb_vm_t *vm) { rb_execution_context_t *ec = GET_EC(); - const unsigned long block_mask = POSTPONED_JOB_INTERRUPT_MASK|TRAP_INTERRUPT_MASK; - volatile unsigned long saved_mask = ec->interrupt_mask & block_mask; + const rb_atomic_t block_mask = POSTPONED_JOB_INTERRUPT_MASK|TRAP_INTERRUPT_MASK; + volatile rb_atomic_t saved_mask = ec->interrupt_mask & block_mask; VALUE volatile saved_errno = ec->errinfo; ec->errinfo = Qnil; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/