开发者

Illegal instruction: 4 when using Rails 3 ActionMailer

I am trying to use gmail sending in my development environment in Rails 3.1. The code is the following:

config/development.rb

config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
:address              => "smtp.gmail.com",
:port                 => 587,
:domain               => 'domain.com',
:user_name            => 'domain',
:password             => 'password',
:authentication       => 'plain',
:enable_starttls_auto => true  }

the controller

def forward_message(message)
  @message = message
  mail(:to =开发者_运维百科> "test_account@gmail.com", :subject => "Test message")
end

and the view only contains the text "test"

I call the ActionMailer method like this

MessageMailer.forward_message(@message).deliver

The problem is that rails crashes giving out "Illegal instruction: 4"

I want to note that the code works on the production machine and I am using Rails 3.1rc5. Please advise me on how to debug this error.

Thanks for the help!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜