mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-17 11:21:39 -10:00
* Hi Mono Team, This commit fixes an interesting bug that relates to the System.Net.Http nuget packages. So the short story is that System.Net.Http can view the internals of this assembly because of InternalsVisibleTo and the HttpClient references System.Net.Logging's "On" _property_. The problem is that mono has implemented "On" as a _field_ . When the latest version of System.Net.Http.HttpClient tries to invoke a SyncAsync using Mono, you get a MissingMethodException because: bool System.Net.Logging.get_On() does not exist. This commit is simple and only changes the signature of On to match that of the reference source (property instead of field). This will cause the Missing Method Exception not to be thrown. * Fix indentation
93 lines
1.9 KiB
C#
93 lines
1.9 KiB
C#
using System.Diagnostics;
|
|
|
|
namespace System.Net {
|
|
static class Logging
|
|
{
|
|
|
|
internal static bool On {
|
|
get {
|
|
return false;
|
|
}
|
|
}
|
|
|
|
internal static TraceSource Web {
|
|
get {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
internal static TraceSource HttpListener {
|
|
get {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
internal static TraceSource Sockets {
|
|
get {
|
|
return null;
|
|
}
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Enter(TraceSource traceSource, object obj, string method, object paramObject) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Enter(TraceSource traceSource, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Enter(TraceSource traceSource, string msg, string parameters) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Exception(TraceSource traceSource, object obj, string method, Exception e) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Exit(TraceSource traceSource, object obj, string method, object retObject) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Exit(TraceSource traceSource, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void Exit(TraceSource traceSource, string msg, string parameters) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void PrintInfo(TraceSource traceSource, object obj, string method, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void PrintInfo(TraceSource traceSource, object obj, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void PrintInfo(TraceSource traceSource, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void PrintWarning(TraceSource traceSource, object obj, string method, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void PrintWarning(TraceSource traceSource, string msg) {
|
|
}
|
|
|
|
[Conditional ("TRACE")]
|
|
internal static void PrintError(TraceSource traceSource, string msg) {
|
|
}
|
|
}
|
|
|
|
#if MOBILE
|
|
|
|
class TraceSource
|
|
{
|
|
|
|
}
|
|
|
|
#endif
|
|
}
|