[Rubygems-developers] ZLib bites us again.

Jim Weirich jim.weirich at gmail.com
Wed Jun 20 01:10:10 EDT 2007


Version 0.9.3 (IIRC) set the ZLib code in package.rb to always read  
from a memory string rather than a FileIO object.  This was to avoid  
buffer errors on Windows boxen.  Unfortunately, it seems that we  
still get zlib problems.  Jamis Buck reported a problem with the  
capistrano gem on windows XP.  After some deep diving, he came up  
with with a workaround version of zipped_stream that doesn't blow up  
with a buffer error ... at least for this time around.  Essentially,  
Jamis's fix replaces GZipReader with some Ruby code that does the  
equivalent directly with ZLib calls.

I've made a beta version of RubyGems with his patch (you can get it  
with: gem update --system --source http://onestepback.org/betagems).

Jamis points out that this is cargo cult programming at its finest.   
I.e. we really don't know *why* it fixes it.  All we know is that it  
does fix it in this one instance.  We really need someone to dive  
into ZLib and see if we can get the windows version fixed.

I've attached Jamis's original email.  He has a slightly longer  
version we may want to consider if this fix seems to be worthwhile.   
Thank you for your time.



-- 
-- Jim Weirich
-- jim at weirichhouse.org



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/rubygems-developers/attachments/20070620/608e6ee8/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Jamis.rtf
Type: text/rtf
Size: 2127 bytes
Desc: not available
Url : http://rubyforge.org/pipermail/rubygems-developers/attachments/20070620/608e6ee8/attachment.rtf 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/rubygems-developers/attachments/20070620/608e6ee8/attachment-0001.html 


More information about the Rubygems-developers mailing list