src/ruby_supportlib/phusion_passenger/admin_tools/instance.rb
# Returns the Core's PID, or nil if it is not running
# or isn't finished initializing.
Returns the Core's PID, or nil if it is not running
or isn't finished initializing.
Returns the Core ' s PID or nil if it is not running or isn ' t finished initializing .
def core_pid
        @core_pid ||= begin
          begin
            data = File.read("#{@path}/core.pid")
            if data.empty?
              nil
            else
              data.to_i
            end
          rescue Errno::ENOENT
            nil
          end
        end
      end
def core_pid @core_pid ||= begin begin data = File . read ( "#{@path}/core.pid" ) if data . empty? nil else data . to_i end rescue Errno :: ENOENT nil end end end
Returns the Core's PID, or nil if it is not running
or isn't finished initializing.
Returns the Core ' s PID or nil if it is not running or isn ' t finished initializing .