28 May
2011
28 May
'11
2:13 p.m.
While experimenting with array controllers and NSTableViews, I was facing huge memory leaks. I thought the culprits were the Cocoa bindings but I have discovered that the Nokogiri gem is what is causing them. The following little test doesn't leak under Ruby 1.9.2 compiled with MacPorts, so it seems there is a problem with the underlying linking with libxml2 instead. -------------------------------------------------------------- require 'rubygems' require 'nokogiri' loop do doc = Nokogiri::HTML('<html><body><p>TEST </p></body></html>') p = doc.css("p")[0].text print p end -------------------------------------------------------------- -- Guido