Replace TagLib.Portable.dll with taglib-sharp submodule

This commit is contained in:
Bond_009 2018-12-11 14:55:33 +01:00
parent b8c275709c
commit f2a7965101
3 changed files with 86 additions and 88 deletions

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "ThirdParty/taglib-sharp"]
path = ThirdParty/taglib-sharp
url = git@github.com:mono/taglib-sharp.git

View File

@ -3,9 +3,7 @@
<ItemGroup>
<ProjectReference Include="..\MediaBrowser.Controller\MediaBrowser.Controller.csproj" />
<ProjectReference Include="..\MediaBrowser.Model\MediaBrowser.Model.csproj" />
<Reference Include="TagLib.Portable">
<HintPath>..\ThirdParty\taglib\TagLib.Portable.dll</HintPath>
</Reference>
<ProjectReference Include="..\ThirdParty\taglib-sharp\src\taglib-sharp.csproj" />
</ItemGroup>
<ItemGroup>

View File

@ -57,9 +57,7 @@ namespace Emby.Photos
{
try
{
using (var fileStream = _fileSystem.OpenRead(item.Path))
{
using (var file = TagLib.File.Create(new StreamFileAbstraction(Path.GetFileName(item.Path), fileStream, null)))
using (var file = TagLib.File.Create(item.Path))
{
var image = file as TagLib.Image.File;
@ -172,7 +170,6 @@ namespace Emby.Photos
}
}
}
}
catch (Exception e)
{
_logger.ErrorException("Image Provider - Error reading image tag for {0}", e, item.Path);