mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-15 05:04:15 +01:00
cleanup: remove obsolete Util.HttpClient, Util.CopyTo()
This commit is contained in:
parent
292e0c2df8
commit
8bd0cb0c57
1 changed files with 0 additions and 22 deletions
|
|
@ -35,13 +35,6 @@ public static class Util
|
|||
private static ulong moduleStartAddr;
|
||||
private static ulong moduleEndAddr;
|
||||
|
||||
/// <summary>
|
||||
/// Gets an httpclient for usage.
|
||||
/// Do NOT await this.
|
||||
/// </summary>
|
||||
[Obsolete($"Use Service<{nameof(HappyHttpClient)}> instead.")]
|
||||
public static HttpClient HttpClient { get; } = Service<HappyHttpClient>.Get().SharedHttpClient;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the assembly version of Dalamud.
|
||||
/// </summary>
|
||||
|
|
@ -493,21 +486,6 @@ public static class Util
|
|||
return Encoding.UTF8.GetString(mso.ToArray());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Copy one stream to another.
|
||||
/// </summary>
|
||||
/// <param name="src">The source stream.</param>
|
||||
/// <param name="dest">The destination stream.</param>
|
||||
/// <param name="len">The maximum length to copy.</param>
|
||||
[Obsolete("Use Stream.CopyTo() instead", true)]
|
||||
public static void CopyTo(Stream src, Stream dest, int len = 4069)
|
||||
{
|
||||
var bytes = new byte[len];
|
||||
int cnt;
|
||||
|
||||
while ((cnt = src.Read(bytes, 0, bytes.Length)) != 0) dest.Write(bytes, 0, cnt);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Heuristically determine if Dalamud is running on Linux/WINE.
|
||||
/// </summary>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue