diff options
Diffstat (limited to 'src/TagFile.cxx')
-rw-r--r-- | src/TagFile.cxx | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/TagFile.cxx b/src/TagFile.cxx index 3d076ca0d..593c1fcb2 100644 --- a/src/TagFile.cxx +++ b/src/TagFile.cxx @@ -19,6 +19,9 @@ #include "config.h" #include "TagFile.hxx" +#include "tag/Generic.hxx" +#include "tag/TagHandler.hxx" +#include "tag/TagBuilder.hxx" #include "fs/Path.hxx" #include "util/UriUtil.hxx" #include "util/Error.hxx" @@ -94,3 +97,15 @@ tag_file_scan(Path path_fs, const TagHandler &handler, void *handler_ctx) return tfs.Scan(plugin); }); } + +bool +tag_file_scan(Path path, TagBuilder &builder) +{ + if (!tag_file_scan(path, full_tag_handler, &builder)) + return false; + + if (builder.IsEmpty()) + ScanGenericTags(path, full_tag_handler, &builder); + + return true; +} |