fixed decompiler errors - project compiles

This commit is contained in:
2017-10-06 18:20:35 +02:00
parent 2d8b6914b8
commit 9cefa0e9dd
40 changed files with 420 additions and 411 deletions

View File

@@ -68,7 +68,7 @@ namespace Rei.Net.HttpServer
public void Close()
{
this.Dispose();
((IDisposable)this).Dispose();
}
protected virtual void Dispose(bool disposing)

View File

@@ -1045,9 +1045,9 @@ namespace Rei.Net.HttpServer
}
finally
{
IEnumerator enumerator;
if (enumerator is IDisposable)
(enumerator as IDisposable).Dispose();
//IEnumerator enumerator;
//if (enumerator is IDisposable)
// (enumerator as IDisposable).Dispose();
}
stringList.Add("");
stringList.Add("");
@@ -1377,7 +1377,12 @@ label_6:
return str + "\r\n" + this._remoteep.ToString() + "\r\n" + this._req_state.ToString();
}
private enum BodyLengthType
public void Dispose()
{
Dispose(true);
}
private enum BodyLengthType
{
Unknown,
NoBody,

View File

@@ -151,5 +151,10 @@ namespace Rei.Net.HttpServer
{
return this._requestline + " " + this._host;
}
public void Dispose()
{
Dispose(true);
}
}
}

View File

@@ -228,10 +228,9 @@ label_18:
public IPEndPoint[] GetExternalEndpoints()
{
List<IPEndPoint> ipEndPointList = new List<IPEndPoint>();
List<UPnPManager.portmappingentry>.Enumerator enumerator;
List<UPnPManager.portmappingentry>.Enumerator enumerator = this.mappinglist.GetEnumerator();
try
{
enumerator = this.mappinglist.GetEnumerator();
while (enumerator.MoveNext())
{
UPnPManager.portmappingentry current = enumerator.Current;
@@ -264,10 +263,9 @@ label_18:
{
IPInterfaceProperties ipProperties = networkInterface.GetIPProperties();
IPAddress internalip = (IPAddress) null;
IEnumerator<UnicastIPAddressInformation> enumerator1;
IEnumerator<UnicastIPAddressInformation> enumerator1 = ipProperties.UnicastAddresses.GetEnumerator();
try
{
enumerator1 = ipProperties.UnicastAddresses.GetEnumerator();
while (enumerator1.MoveNext())
{
UnicastIPAddressInformation current = enumerator1.Current;
@@ -283,12 +281,11 @@ label_18:
if (enumerator1 != null)
enumerator1.Dispose();
}
IEnumerator<GatewayIPAddressInformation> enumerator2;
IEnumerator<GatewayIPAddressInformation> enumerator2 = ipProperties.GatewayAddresses.GetEnumerator();
if (internalip != null)
{
try
{
enumerator2 = ipProperties.GatewayAddresses.GetEnumerator();
while (enumerator2.MoveNext())
{
GatewayIPAddressInformation current = enumerator2.Current;