From 68f5e2361a81493297869d5a06aae8841dcefd49 Mon Sep 17 00:00:00 2001 From: akr Date: Fri, 28 Jan 2005 08:18:59 +0000 Subject: [PATCH] * lib/resolv.rb (Resolv::DNS::Config.parse_resolv_conf): parse options line for ndots option. (Resolv::Hosts#lazy_initialize): return self. (Resolv::DNS#lazy_initialize): ditto. (Resolv::DNS::Config#lazy_initialize): ditto. Suggested by Sam Roberts. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7839 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 9 +++++++++ lib/resolv.rb | 10 ++++++++++ 2 files changed, 19 insertions(+) diff --git a/ChangeLog b/ChangeLog index 08a47a72d8..684fec5fe4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +Fri Jan 28 17:16:55 2005 Tanaka Akira + + * lib/resolv.rb (Resolv::DNS::Config.parse_resolv_conf): + parse options line for ndots option. + (Resolv::Hosts#lazy_initialize): return self. + (Resolv::DNS#lazy_initialize): ditto. + (Resolv::DNS::Config#lazy_initialize): ditto. + Suggested by Sam Roberts. + Thu Jan 27 17:15:03 2005 NAKAMURA Usaku * ext/tk/extconf.rb: support new tk scheme on bccwin32. diff --git a/lib/resolv.rb b/lib/resolv.rb index 80536fbdd8..769ebe34f5 100644 --- a/lib/resolv.rb +++ b/lib/resolv.rb @@ -319,6 +319,7 @@ class Resolv @initialized = true end } + self end def getaddress(name) @@ -397,6 +398,7 @@ class Resolv @initialized = true end } + self end def close @@ -739,6 +741,13 @@ class Resolv when 'search' next if args.empty? search = args + when 'options' + args.each {|arg| + case arg + when /\Andots:(\d+)\z/ + ndots = $1.to_i + end + } end } } @@ -814,6 +823,7 @@ class Resolv @initialized = true end } + self end def single?