/usr/lib/ruby/vendor_ruby/celluloid/internals/responses.rb is in ruby-celluloid-essentials 0.20.5-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | module Celluloid
module Internals
# Responses to calls
class Response
attr_reader :call, :value
def initialize(call, value)
@call, @value = call, value
end
def dispatch
@call.task.resume self
end
# Call completed successfully
class Success < Response; end
# Call was aborted due to sender error
class Error < Response
def value
ex = super
ex = ex.cause if ex.is_a? Celluloid::AbortError
if ex.backtrace
ex.backtrace << "(celluloid):0:in `remote procedure call'"
ex.backtrace.concat(caller)
end
fail ex
end
end
class Block
def initialize(call, result)
@call = call
@result = result
end
def dispatch
@call.task.resume(@result)
end
end
end
end
end
|