summaryrefslogtreecommitdiff
path: root/lib/drb/extservm.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/drb/extservm.rb')
-rw-r--r--lib/drb/extservm.rb10
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/drb/extservm.rb b/lib/drb/extservm.rb
index 216fe8dcee..8a7fc316af 100644
--- a/lib/drb/extservm.rb
+++ b/lib/drb/extservm.rb
@@ -79,7 +79,15 @@ module DRb
@servers[name] = false
end
uri = @uri || DRb.uri
- Process.detach spawn("#{command} #{uri} #{name}")
+ if command.respond_to? :to_ary
+ command = command.to_ary + [uri, name]
+ pid = spawn(*command)
+ else
+ pid = spawn("#{command} #{uri} #{name}")
+ end
+ th = Process.detach(pid)
+ th[:drb_service] = name
+ th
end
end
end