Protect again memory overruns.

Get rid of warnings.
This commit is contained in:
mvandervoord
2019-10-23 17:12:18 -04:00
parent 8f1156dddc
commit cda809765e
3 changed files with 16 additions and 3 deletions
+5 -1
View File
@@ -73,7 +73,11 @@ class CMockConfig
treat_as_map.merge!(@options[:treat_as])
@options[:treat_as] = treat_as_map
@options.each_key { |key| eval("def #{key.to_s}() return @options[:#{key.to_s}] end") }
@options.each_key do |key|
unless methods.include?(key)
eval("def #{key.to_s}() return @options[:#{key.to_s}] end")
end
end
end
def load_config_file_from_yaml yaml_filename