Maybe fix deadlock
This commit is contained in:
parent
f96764fd10
commit
1473dace87
|
@ -15,7 +15,7 @@ namespace Tesses.YouTubeDownloader.Net6
|
|||
TYTDCurrentDirectory currentDirectory=new TYTDCurrentDirectory(new HttpClient());
|
||||
TYTDServer server=new TYTDServer(currentDirectory);
|
||||
server.RootServer.Server=new StaticServer("WebSite");
|
||||
currentDirectory.CanDownload=false;
|
||||
currentDirectory.CanDownload=true;
|
||||
HttpServerListener listener=new HttpServerListener(new System.Net.IPEndPoint(System.Net.IPAddress.Any,3252),server.InnerServer);
|
||||
currentDirectory.StartLoop();
|
||||
TYTDStorage.FFmpeg ="/usr/bin/ffmpeg";
|
||||
|
@ -24,4 +24,4 @@ namespace Tesses.YouTubeDownloader.Net6
|
|||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -59,9 +59,9 @@ namespace Tesses.YouTubeDownloader
|
|||
}
|
||||
|
||||
|
||||
public bool FileExists(string path)
|
||||
public bool FileExists(string path)
|
||||
{
|
||||
return FileExistsAsync(path).GetAwaiter().GetResult();
|
||||
return Task.Run(()=>FileExistsAsync(path)).GetAwaiter().GetResult();
|
||||
}
|
||||
|
||||
public virtual async IAsyncEnumerable<string> GetVideoIdsAsync()
|
||||
|
@ -213,6 +213,7 @@ namespace Tesses.YouTubeDownloader
|
|||
public virtual bool DownloadExists(string url)
|
||||
{
|
||||
string enc=$"FileInfo/{B64.Base64UrlEncodes(url)}.json";
|
||||
|
||||
return FileExists(enc);
|
||||
}
|
||||
public virtual bool PlaylistInfoExists(PlaylistId id)
|
||||
|
@ -245,7 +246,7 @@ namespace Tesses.YouTubeDownloader
|
|||
|
||||
public virtual bool DirectoryExists(string path)
|
||||
{
|
||||
return DirectoryExistsAsync(path).GetAwaiter().GetResult();
|
||||
return Task.Run(()=>DirectoryExistsAsync(path)).GetAwaiter().GetResult();
|
||||
}
|
||||
|
||||
public virtual IEnumerable<string> EnumerateFiles(string path)
|
||||
|
|
|
@ -7,9 +7,9 @@
|
|||
<PackageId>Tesses.YouTubeDownloader</PackageId>
|
||||
<Author>Mike Nolan</Author>
|
||||
<Company>Tesses</Company>
|
||||
<Version>1.1.9</Version>
|
||||
<AssemblyVersion>1.1.9</AssemblyVersion>
|
||||
<FileVersion>1.1.9</FileVersion>
|
||||
<Version>1.2.0</Version>
|
||||
<AssemblyVersion>1.2.0</AssemblyVersion>
|
||||
<FileVersion>1.2.0</FileVersion>
|
||||
<Description>A YouTube Downloader</Description>
|
||||
<PackageLicenseExpression>LGPL-3.0-only</PackageLicenseExpression>
|
||||
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
|
||||
|
|
Loading…
Reference in New Issue