Methods

Class/Module Index [+]

Quicksearch

Process

Public Class Methods

timed_waitpid(pid, max_time) click to toggle source
# File lib/phusion_passenger/utils.rb, line 1036
def self.timed_waitpid(pid, max_time)
        done = false
        start_time = Time.now
        while Time.now - start_time < max_time && !done
                done = Process.waitpid(pid, Process::WNOHANG)
                sleep 0.1 if !done
        end
        return !!done
rescue Errno::ECHILD
        return true
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.