summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen <stephen@puppetlabs.com>2012-08-14 19:30:14 +0100
committerStephen <stephen@puppetlabs.com>2012-08-14 19:30:14 +0100
commit8d2a8c859d928700350d48965dcf01d279289393 (patch)
treec595fff1d891d4660639448a832cf109c71f0f98
parentd2c1e07e8088fb2372d258cfdd27ee4aab10cef1 (diff)
downloadpuppet-inifile-8d2a8c859d928700350d48965dcf01d279289393.tar.gz
puppet-inifile-8d2a8c859d928700350d48965dcf01d279289393.tar.bz2
make the regex less matchy
-rw-r--r--lib/puppet/util/ini_file.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/puppet/util/ini_file.rb b/lib/puppet/util/ini_file.rb
index 0505462..b951b3f 100644
--- a/lib/puppet/util/ini_file.rb
+++ b/lib/puppet/util/ini_file.rb
@@ -5,8 +5,8 @@ module Puppet
module Util
class IniFile
- SECTION_REGEX = /^\s*\[([\S.]+)\]\s*$/
- SETTING_REGEX = /^\s*([\S]+)\s*=\s*([\S]+)\s*$/
+ SECTION_REGEX = /^\s*\[([\w\d\.\\\/\-]+)\]\s*$/
+ SETTING_REGEX = /^\s*([\w\d\.\\\/\-]+)\s*=\s*([\S]+)\s*$/
def initialize(path)
@path = path