Commit b1d60b5c authored by Max Kellermann's avatar Max Kellermann

TagArchive: use InputStreamPtr

parent 99a05c56
......@@ -35,11 +35,10 @@ tag_archive_scan(Path path, const TagHandler &handler, void *handler_ctx)
Mutex mutex;
Cond cond;
auto *is = OpenArchiveInputStream(path, mutex, cond, IgnoreError());
if (is == nullptr)
InputStreamPtr is(OpenArchiveInputStream(path, mutex, cond,
IgnoreError()));
if (!is)
return false;
bool result = tag_stream_scan(*is, handler, handler_ctx);
delete is;
return result;
return tag_stream_scan(*is, handler, handler_ctx);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment