I have this error while executing my Ruby Script


when I am executing Ruby Script, Program is abruptly terminating and
it’s printing text that it’s a segmentation fault. Since it’s stopping
the Ruby Interpreter, i couldn’t catch this error in rescue block also.
So could anyone please provide me the solution ?


So you don’t show any of your code, the error message, your operating
system details, your version of Ruby… and you expect a magical fix?

hi Joel,

today is holiday here, I have my code in my office. I will give you all
the detail to you on Monday. By the way I give you some of the details
which you have asked me.

My operating System : Windows 7
Ruby version :1.8.7

I will post that exact error message and code on Monday because I don’t
have the code right now.


All I can find about segmentation faults in this context suggests that
it’s caused by a bug.

Try updating your gems.
If possible, upgrade your Ruby version since the one you’re using is
very old
(https://www.ruby-lang.org/en/news/2013/06/30/we-retire-1-8-7/), and
will contain bugs which have been fixed in newer versions.

hi Joel P.

You have asked me the details of my error and code,

Here is my code

def modalDialog(flg,flag=false)
sleep 5
if (flg == ‘Ok’)


And here is my error,

[BUG] Segmentation fault
ruby 1.8.7 (2011-02-18 patchlevel 334) [i386-mingw32]

This application has requested the Runtime to terminate it in an unusual
Please contact the application’s support team for more information.

This error is coming for me when I execute this statement
“$browser.modal_dialog().exists?” So Can you suggest me what type of
Error is this? how would I resolve this problem?


I resolved this issue yesterday evening and I forgot to reply to you and
exactly as you said I upgrade a gem named ffi this issue was resolved.
And yes we are planning to move into a higher version of Ruby soon.

Thank you.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs