bzip2-ruby
bzip2-ruby copied to clipboard
Set dependencies with ~> to prevent major verion breakage
Recent PRs #25 and #26 failed because rspec 3.0 matches ">= 2.0.0". This PR pins rspec, rake, rake-compiler as needed.
Now the builds are broken due to a memory issue. Also updated .travis.yml to build Ruby 2.0 and 2.1.
The situation is quite confusing but basically I removed a previous memory leak fix. Maybe there really is a memory leak but the fix caused segfaults for me in certain cases. I only use this library in rake tasks so short-term memory leaks aren't a big issue for me.
:+1:
Er, what I meant by that was - +1 to this change. The memory corruption thing is a separate issue. I really need to figure out what to do with this gem :\
In short, it probably needs to be rewritten or abandoned (I mean, it is now)
I remembered that ALLOC_N
should be paired with xfree
and not ordinary free, and set
bzf->buf = NULL` after each free. Now it just doesn't work instead of crashing. Progress!
Thanks for taking the time to look into this, it is appreciated.