[#5219] Segmentation fault in timeout.rb — Michel Pastor <K@...>

Hi,

18 messages 2005/06/16
[#5220] Re: Segmentation fault in timeout.rb — Eric Hodel <drbrain@...7.net> 2005/06/16

[#5221] Re: Segmentation fault in timeout.rb — Michel Pastor <K@...> 2005/06/16

On Fri, 17 Jun 2005 05:03:18 +0900

[#5223] Re: Segmentation fault in timeout.rb — nobu.nokada@... 2005/06/17

Hi,

[#5296] Subversion — Shugo Maeda <shugo@...>

Hi,

64 messages 2005/06/30
[#5297] Re: Subversion — Curt Hibbs <curt@...> 2005/06/30

Shugo Maeda wrote:

[#5298] Re: Subversion — Nikolai Weibull <mailing-lists.ruby-core@...> 2005/06/30

Curt Hibbs wrote:

[#5301] Re: Subversion — Austin Ziegler <halostatue@...> 2005/06/30

On 6/30/05, Nikolai Weibull

[#5304] Re: Subversion — Nikolai Weibull <mailing-lists.ruby-core@...> 2005/06/30

Austin Ziegler wrote:

[#5305] Re: Subversion — Austin Ziegler <halostatue@...> 2005/06/30

On 6/30/05, Nikolai Weibull

[#5307] Re: Subversion — mathew <meta@...> 2005/06/30

Austin Ziegler wrote:

[#5308] Re: Subversion — Austin Ziegler <halostatue@...> 2005/06/30

On 6/30/05, mathew <meta@pobox.com> wrote:

[#5311] Re: Subversion — mathew <meta@...> 2005/07/01

Austin Ziegler wrote:

[#5323] Re: Subversion — Austin Ziegler <halostatue@...> 2005/07/01

On 7/1/05, mathew <meta@pobox.com> wrote:

[#5325] Re: Subversion — Nikolai Weibull <mailing-lists.ruby-core@...> 2005/07/01

Austin Ziegler wrote:

Segmentation fault in timeout.rb

From: Michel Pastor <K@...>
Date: 2005-06-16 18:51:18 UTC
List: ruby-core #5219
Hi,
it seems I discovered a bug since I can get a reproducible segfault on different hardware when trying to use a freshly created rails application using a sqlite3 database running on a webrick. I didn't test with other db so I dont know if that comes from sqlite3-ruby gem. The following instructions triggers the problem on the two systems I tested them on:

using ruby 1.8.2, sqlite3-ruby 1.1.0 and rails 0.12.1 installed with rubygems, gcc 3.4.3, glibc 3.4.3 all on a linux 2.6 kernel

 > rails testapp
  [...]
 > cd testapp
 > cat << EOF > config/database.yml
development:
  adapter: sqlite3
  dbfile:  db/rails-devlopment.db

test:
  adapter: sqlite3
  dbfile:  db/rails-devlopment.db

production:
  adapter: sqlite3
  dbfile:  db/rails-devlopment.db
EOF
 > echo 'create table films (id integer AUTO_INCREMENT PRIMARY KEY, title varchar(255) NOT NULL);' | sqlite3 db/rails-development.db
 > script/generate model Film
  [...]
 > script/generate controller Films
  [...]
 > vim app/controllers/films_controller.rb
  [ add "scaffold :film" in FilmsController class ]
 > ruby script/server

I'm connecting to the server on http://myname:3000/films/list
and trying to add a film gives:

*1) without debugging enabled

=> Rails application started on http://0.0.0.0:3000
[2005-06-16 09:07:12] INFO  WEBrick 1.3.1
[2005-06-16 09:07:12] INFO  ruby 1.8.2 (2004-12-25) [i686-linux]
[2005-06-16 09:07:12] INFO  WEBrick::HTTPServer#start: pid=27257 port=3000
X.X.X.X - - [16/Jun/2005:09:07:20 CEST] "GET /films HTTP/1.1" 200 1281
- -> /films
X.X.X.X - - [16/Jun/2005:09:07:21 CEST] "GET /favicon.ico HTTP/1.1" 304 0
- -> /favicon.ico
X.X.X.X - - [16/Jun/2005:09:07:23 CEST] "GET /films/new HTTP/1.1" 200 1414
http://myname:3000/films -> /films/new
X.X.X.X - - [16/Jun/2005:09:07:26 CEST] "GET /films/new HTTP/1.1" 200 1414
http://myname:3000/films -> /films/new
X.X.X.X - - [16/Jun/2005:09:07:30 CEST] "GET /films/list HTTP/1.1" 200 1281
http://myname:3000/films/new -> /films/list
X.X.X.X - - [16/Jun/2005:09:07:31 CEST] "GET /films/new HTTP/1.1" 200 1414
http://myname:3000/films/list -> /films/new
X.X.X.X - - [16/Jun/2005:09:07:34 CEST] "POST /films/create HTTP/1.1" 302 91
http://myname:3000/films/new -> /films/create
deadlock 0xb76d3ce8: run:-/usr/lib/ruby/1.8/timeout.rb:41: [BUG] Segmentation fault
ruby 1.8.2 (2004-12-25) [i686-linux]

Aborted

*2) with debugging enabled

=> Rails application started on http://0.0.0.0:3000
[2005-06-16 19:50:33] INFO  WEBrick 1.3.1
[2005-06-16 19:50:33] INFO  ruby 1.8.2 (2004-12-25) [i686-linux]
[2005-06-16 19:50:33] INFO  WEBrick::HTTPServer#start: pid=4214 port=3000
X.X.X.X - - [16/Jun/2005:19:50:44 CEST] "GET /films/list HTTP/1.1" 200 1281
- -> /films/list
deadlock 0xb75e5000: run:-  - :0
deadlock 0xb7e73798: sleep:ST(1118944246.320441) (main) - /usr/lib/ruby/1.8/webrick/server.rb:88
deadlock 0xb774d104: sleep:T(1118944275.021337)  - /usr/lib/ruby/1.8/timeout.rb:41
[2005-06-16 19:50:45] ERROR fatal: Thread(0xb774d104): deadlock
        /usr/lib/ruby/1.8/timeout.rb:41:in `start'

thx
- Michel

In This Thread

Prev Next