# Bug segmentation fault

**URL:** <https://www.ruby-forum.com/t/bug-segmentation-fault/73863>\
**Category:** Ruby\
**Created:** [October 27, 2006, 5:49pm UTC](https://www.ruby-forum.com/t/bug-segmentation-fault/73863 "2006-10-27T17:49:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![wkc](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/3be4f8/32.png) [@wkc](https://www.ruby-forum.com/u/wkc)\
**Post date:** [October 27, 2006, 5:49pm UTC](https://www.ruby-forum.com/t/bug-segmentation-fault/73863/1 "2006-10-27T17:49:11Z")

</div>

I am trying to display the contents of large array (over 1000 rows)  
using arrayName.collect {|x| puts x.inspect}  
However the following occurs:

[Bug] Segmentation fault  
ruby 1.8.5 (20006-08-25) [i386-mswin32]

The same statement works fine with smaller size arrays.

---

<div class="post-metadata">

**Author:** ![wkc](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/3be4f8/32.png) [@wkc](https://www.ruby-forum.com/u/wkc)\
**Post date:** [October 27, 2006, 7:22pm UTC](https://www.ruby-forum.com/t/bug-segmentation-fault/73863/2 "2006-10-27T19:22:06Z")

</div>

On 10/27/06, WKC CCC [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I am trying to display the contents of large array (over 1000 rows)  
> using arrayName.collect {|x| puts x.inspect}  
> However the following occurs:
> 
> [Bug] Segmentation fault  
> ruby 1.8.5 (20006-08-25) [i386-mswin32]
> 
> The same statement works fine with smaller size arrays.

ruby --version  
ruby 1.8.5 (2006-08-25) [i386-cygwin]

c = 0  
ary = []  
1500.times do  
ary \<\< (c…(c+10)).to\_a  
c += 1  
end

ary.collect {|x| puts x.inspect}

This seems to work just fine. Could you please post some sample code  
that prodcues the segmentation fault?

Blessings,  
TwP

---

<div class="post-metadata">

**Author:** ![wkc](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/3be4f8/32.png) [@wkc](https://www.ruby-forum.com/u/wkc)\
**Post date:** [October 29, 2006, 2:20pm UTC](https://www.ruby-forum.com/t/bug-segmentation-fault/73863/3 "2006-10-29T14:20:48Z")

</div>

Hi,

In message “Re: Bug segmentation fault”  
on Sat, 28 Oct 2006 00:49:13 +0900, WKC CCC  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) writes:

|I am trying to display the contents of large array (over 1000 rows)  
|using arrayName.collect {|x| puts x.inspect}  
|However the following occurs:  
|  
|[Bug] Segmentation fault  
|ruby 1.8.5 (20006-08-25) [i386-mswin32]  
|  
|The same statement works fine with smaller size arrays.

This kind of bug is often too difficult to track without error  
reproducing code.

```
						matz.

```
