summaryrefslogtreecommitdiff
path: root/lib/drb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/drb')
-rw-r--r--lib/drb/acl.rb14
-rw-r--r--lib/drb/drb.rb8
-rw-r--r--lib/drb/extserv.rb2
-rw-r--r--lib/drb/extservm.rb2
-rw-r--r--lib/drb/ssl.rb40
-rw-r--r--lib/drb/unix.rb2
6 files changed, 34 insertions, 34 deletions
diff --git a/lib/drb/acl.rb b/lib/drb/acl.rb
index cf51687987f..29a378199f4 100644
--- a/lib/drb/acl.rb
+++ b/lib/drb/acl.rb
@@ -234,17 +234,17 @@ end
if __FILE__ == $0
# example
list = %w(deny all
- allow 192.168.1.1
+ allow 192.168.1.1
allow ::ffff:192.168.1.2
allow 192.168.1.3
- )
+ )
- addr = ["AF_INET", 10, "lc630", "192.168.1.3"]
+ addr = ["AF_INET", 10, "lc630", "192.168.1.3"]
- acl = ACL.new
- p acl.allow_addr?(addr)
+ acl = ACL.new
+ p acl.allow_addr?(addr)
- acl = ACL.new(list, ACL::DENY_ALLOW)
- p acl.allow_addr?(addr)
+ acl = ACL.new(list, ACL::DENY_ALLOW)
+ p acl.allow_addr?(addr)
end
diff --git a/lib/drb/drb.rb b/lib/drb/drb.rb
index c93762ca74f..b4ccc113066 100644
--- a/lib/drb/drb.rb
+++ b/lib/drb/drb.rb
@@ -563,7 +563,7 @@ module DRb
def load(soc) # :nodoc:
begin
- sz = soc.read(4) # sizeof (N)
+ sz = soc.read(4) # sizeof (N)
rescue
raise(DRbConnError, $!.message, $!.backtrace)
end
@@ -812,7 +812,7 @@ module DRb
[host, port, option]
else
raise(DRbBadScheme, uri) unless uri =~ /^druby:/
- raise(DRbBadURI, 'can\'t parse uri:' + uri)
+ raise(DRbBadURI, 'can\'t parse uri:' + uri)
end
end
@@ -1117,7 +1117,7 @@ module DRb
result.backtrace.each do |x|
break if /`__send__'$/ =~ x
if /^\(druby:\/\// =~ x
- bt.push(x)
+ bt.push(x)
else
bt.push(prefix + x)
end
@@ -1584,7 +1584,7 @@ module DRb
Thread.start(@protocol.accept) do |client|
@grp.add Thread.current
Thread.current['DRb'] = { 'client' => client ,
- 'server' => self }
+ 'server' => self }
loop do
begin
succ = false
diff --git a/lib/drb/extserv.rb b/lib/drb/extserv.rb
index 4ef3253b777..bb11211cd18 100644
--- a/lib/drb/extserv.rb
+++ b/lib/drb/extserv.rb
@@ -1,6 +1,6 @@
=begin
external service
- Copyright (c) 2000,2002 Masatoshi SEKI
+ Copyright (c) 2000,2002 Masatoshi SEKI
=end
require 'drb/drb'
diff --git a/lib/drb/extservm.rb b/lib/drb/extservm.rb
index 71a5cf7a566..216fe8dceef 100644
--- a/lib/drb/extservm.rb
+++ b/lib/drb/extservm.rb
@@ -1,6 +1,6 @@
=begin
external service manager
- Copyright (c) 2000 Masatoshi SEKI
+ Copyright (c) 2000 Masatoshi SEKI
=end
require 'drb/drb'
diff --git a/lib/drb/ssl.rb b/lib/drb/ssl.rb
index e15b5915c9e..17e2a73d853 100644
--- a/lib/drb/ssl.rb
+++ b/lib/drb/ssl.rb
@@ -60,10 +60,10 @@ module DRb
when 0; $stderr.putc "." # BN_generate_prime
when 1; $stderr.putc "+" # BN_generate_prime
when 2; $stderr.putc "*" # searching good prime,
- # n = #of try,
- # but also data from BN_generate_prime
+ # n = #of try,
+ # but also data from BN_generate_prime
when 3; $stderr.putc "\n" # found good prime, n==0 - p, n==1 - q,
- # but also data from BN_generate_prime
+ # but also data from BN_generate_prime
else; $stderr.putc "*" # BN_generate_prime
end
}
@@ -82,16 +82,16 @@ module DRb
cert.extensions = [
ef.create_extension("basicConstraints","CA:FALSE"),
ef.create_extension("subjectKeyIdentifier", "hash") ]
- ef.issuer_certificate = cert
- cert.add_extension(ef.create_extension("authorityKeyIdentifier",
- "keyid:always,issuer:always"))
- if comment = self[:SSLCertComment]
- cert.add_extension(ef.create_extension("nsComment", comment))
- end
- cert.sign(rsa, OpenSSL::Digest::SHA1.new)
+ ef.issuer_certificate = cert
+ cert.add_extension(ef.create_extension("authorityKeyIdentifier",
+ "keyid:always,issuer:always"))
+ if comment = self[:SSLCertComment]
+ cert.add_extension(ef.create_extension("nsComment", comment))
+ end
+ cert.sign(rsa, OpenSSL::Digest::SHA1.new)
- @cert = cert
- @pkey = rsa
+ @cert = cert
+ @pkey = rsa
end
def setup_ssl_context
@@ -117,7 +117,7 @@ module DRb
[host, port, option]
else
raise(DRbBadScheme, uri) unless uri =~ /^drbssl:/
- raise(DRbBadURI, 'can\'t parse uri:' + uri)
+ raise(DRbBadURI, 'can\'t parse uri:' + uri)
end
end
@@ -172,13 +172,13 @@ module DRb
def accept
begin
- while true
- soc = @socket.accept
- break if (@acl ? @acl.allow_socket?(soc) : true)
- soc.close
- end
- ssl = @config.accept(soc)
- self.class.new(uri, ssl, @config, true)
+ while true
+ soc = @socket.accept
+ break if (@acl ? @acl.allow_socket?(soc) : true)
+ soc.close
+ end
+ ssl = @config.accept(soc)
+ self.class.new(uri, ssl, @config, true)
rescue OpenSSL::SSL::SSLError
warn("#{__FILE__}:#{__LINE__}: warning: #{$!.message} (#{$!.class})") if @config[:verbose]
retry
diff --git a/lib/drb/unix.rb b/lib/drb/unix.rb
index 10465987f22..549ff8cf554 100644
--- a/lib/drb/unix.rb
+++ b/lib/drb/unix.rb
@@ -14,7 +14,7 @@ module DRb
[filename, option]
else
raise(DRbBadScheme, uri) unless uri =~ /^drbunix:/
- raise(DRbBadURI, 'can\'t parse uri:' + uri)
+ raise(DRbBadURI, 'can\'t parse uri:' + uri)
end
end