From 01c6a1f8ff91d25318742ee09ce620e2142088d1 Mon Sep 17 00:00:00 2001 From: akr Date: Tue, 18 Jan 2005 16:29:23 +0000 Subject: [PATCH] * lib/resolv.rb (Resolv::DNS::Config.parse_resolv_conf): ignore domain and search directive without an argument. reported by Sam Roberts. [ruby-talk:126781] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7786 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 6 ++++++ lib/resolv.rb | 2 ++ 2 files changed, 8 insertions(+) diff --git a/ChangeLog b/ChangeLog index 41d2c2f312..25c3a28a93 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Wed Jan 19 01:16:30 2005 Tanaka Akira + + * lib/resolv.rb (Resolv::DNS::Config.parse_resolv_conf): ignore + domain and search directive without an argument. + reported by Sam Roberts. [ruby-talk:126781] + Mon Jan 17 23:33:46 2005 Nobuyoshi Nakada * configure.in (aix): fix typo. [ruby-talk:126401] diff --git a/lib/resolv.rb b/lib/resolv.rb index 069cf5c8f1..84b0d0f10f 100644 --- a/lib/resolv.rb +++ b/lib/resolv.rb @@ -734,8 +734,10 @@ class Resolv when 'nameserver' nameserver += args when 'domain' + next if args.empty? search = [args[0]] when 'search' + next if args.empty? search = args end }