Comment 16 for bug 1572485

Revision history for this message
Fuel Devops McRobotson (fuel-devops-robot) wrote : Fix merged to packages/trusty/ruby-sigar (master)

Reviewed: https://review.fuel-infra.org/20149
Submitter: Pkgs Jenkins <email address hidden>
Branch: master

Commit: f7c2f5a5b80577014117a9ff5f69417692154f80
Author: Alexei Sheplyakov <email address hidden>
Date: Wed Apr 27 11:31:34 2016

Added custom ruby-sigar package to fix segfaults for real

rb_sigar_new does not initialize rb_sigar_t->logger, as a result ruby
runtime garbage collection routines sometimes fail either with a segfault
or an assertion failure:

$ cat test2.rb

 require 'sigar'
 100.times do
   GC.disable
   sigars = []
   100.times do
     sigar = Sigar.new
     sigars << sigar
   end
   GC.enable
   GC.start
   sleep 2
 end

$ ruby test2.rb
/home/asheplyakov/tmp/test2.rb:11: [BUG] rb_gc_mark(): unknown data type 0x0(0x7fbff5cc07c8) non object
ruby 1.9.3p484 (2013-11-22 revision 43786) [x86_64-linux]
[skipped]

Initialize rb_sigar_t->logger to avoid the problem.

The original source has been downloaded from
http://archive.ubuntu.com/ubuntu/pool/universe/r/ruby-sigar/ruby-sigar_0.7.2.orig.tar.gz
http://archive.ubuntu.com/ubuntu/pool/universe/r/ruby-sigar/ruby-sigar_0.7.2-2.debian.tar.gz

Change-Id: I8a1e95fada16ac7b8fa0ace0cfcf83a624935675
Closes-Bug: #1572485