Skip to content

Commit 7ee9a9b

Browse files
committed
config: use absolute path
Signed-off-by: Shizuo Fujita <fujita@clear-code.com>
1 parent 3b43698 commit 7ee9a9b

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

lib/fluent/config/v1_parser.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ def parse_element(root_element, elem_name, attrs = {}, elems = [])
139139
end
140140
end
141141

142-
@on_file_parsed&.call(File.join(@include_basepath, @fname)) if root_element
142+
@on_file_parsed&.call(File.expand_path(File.join(@include_basepath, @fname))) if root_element
143143

144144
return attrs, elems
145145
end

lib/fluent/config/yaml_parser/loader.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ def load(path)
6060
visitor.accept(Psych.parse(f))
6161
end
6262

63-
@on_file_parsed&.call(path.to_s)
63+
@on_file_parsed&.call(File.expand_path(path.to_s))
6464

6565
config
6666
end

0 commit comments

Comments
 (0)