Skip to content

Commit

Permalink
Fix inactivity_timeout issue in pure ruby reactor (eventmachine#108)
Browse files Browse the repository at this point in the history
  • Loading branch information
tmm1 committed Mar 8, 2009
1 parent 7775e1d commit 9a7a7df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/pr_eventmachine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ def get_outbound_data_size
end

def heartbeat
if @inactivity_timeout and (@last_activity + @inactivity_timeout) < Reactor.instance.current_loop_time
if @inactivity_timeout and @inactivity_timeout > 0 and (@last_activity + @inactivity_timeout) < Reactor.instance.current_loop_time
schedule_close true
end
end
Expand Down

0 comments on commit 9a7a7df

Please sign in to comment.