[fxruby-users] FXlistBox.fillItems() segmentation fault - Found Work-around

Alex DeCaria Alex.Decaria at millersville.edu
Sat Apr 3 08:38:33 EDT 2010

As my prior posts show, I was getting very random segmentation faults when repeatedly clearing items from a listbox and then repopulating the items.  I was using the following statements:


This would work for awhile, but after enough iterations of clearing and replacing the items in the listbox it would segmentation faults at the .fillItems call.

I found a workaround.  If instead, I do:

new_list.each { |item| mylistbox.appendItem(item) }

the app works fine and never gives a segmentation fault.  I don't know why the latter is stable, while the former is not, but at least I found a working solution.

I thought I'd post this in case someone else runs into this problem in the future.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/fxruby-users/attachments/20100403/eb1317b3/attachment.html>

More information about the fxruby-users mailing list