1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00

Use Time.now instead of Time.new

This commit is contained in:
Evan Phoenix 2016-02-19 17:05:45 -08:00
parent 6596a4a296
commit cf40a2dbc0

View file

@ -84,10 +84,10 @@ module Puma
def term
begin
if @first_term_sent && (Time.new - @first_term_sent) > @options[:worker_shutdown_timeout]
if @first_term_sent && (Time.now - @first_term_sent) > @options[:worker_shutdown_timeout]
@signal = "KILL"
else
@first_term_sent ||= Time.new
@first_term_sent ||= Time.now
end
Process.kill @signal, @pid