Commit 8bc50e76 authored by justcoding121's avatar justcoding121

Fix bug in dispose param

parent 3ef9595d
...@@ -31,7 +31,7 @@ namespace Titanium.Web.Proxy.EventArguments ...@@ -31,7 +31,7 @@ namespace Titanium.Web.Proxy.EventArguments
} }
/// <summary> /// <summary>
/// Holds a reference to server connection /// Holds a reference to client
/// </summary> /// </summary>
internal ProxyClient ProxyClient { get; set; } internal ProxyClient ProxyClient { get; set; }
...@@ -41,7 +41,7 @@ namespace Titanium.Web.Proxy.EventArguments ...@@ -41,7 +41,7 @@ namespace Titanium.Web.Proxy.EventArguments
public bool IsHttps => WebSession.Request.RequestUri.Scheme == Uri.UriSchemeHttps; public bool IsHttps => WebSession.Request.RequestUri.Scheme == Uri.UriSchemeHttps;
public IPEndPoint ClientEndPoint => (IPEndPoint)TcpClient.Client.RemoteEndPoint; public IPEndPoint ClientEndPoint => (IPEndPoint)ProxyClient.TcpClient.Client.RemoteEndPoint;
/// <summary> /// <summary>
/// A web session corresponding to a single request/response sequence /// A web session corresponding to a single request/response sequence
...@@ -49,11 +49,6 @@ namespace Titanium.Web.Proxy.EventArguments ...@@ -49,11 +49,6 @@ namespace Titanium.Web.Proxy.EventArguments
/// </summary> /// </summary>
public HttpWebClient WebSession { get; set; } public HttpWebClient WebSession { get; set; }
/// <summary>
/// Reference to client connection
/// </summary>
internal TcpClient TcpClient { get; set; }
/// <summary> /// <summary>
/// implement any cleanup here /// implement any cleanup here
......
...@@ -11,6 +11,9 @@ namespace Titanium.Web.Proxy.Http ...@@ -11,6 +11,9 @@ namespace Titanium.Web.Proxy.Http
{ {
public class HttpWebClient public class HttpWebClient
{ {
/// <summary>
/// Connection to server
/// </summary>
internal TcpConnection ServerConnection { get; set; } internal TcpConnection ServerConnection { get; set; }
public Request Request { get; set; } public Request Request { get; set; }
......
...@@ -10,22 +10,22 @@ namespace Titanium.Web.Proxy.Network ...@@ -10,22 +10,22 @@ namespace Titanium.Web.Proxy.Network
public class ProxyClient public class ProxyClient
{ {
/// <summary> /// <summary>
/// TcpClient used to communicate with server /// TcpClient used to communicate with client
/// </summary> /// </summary>
internal TcpClient TcpClient { get; set; } internal TcpClient TcpClient { get; set; }
/// <summary> /// <summary>
/// holds the stream to server /// holds the stream to client
/// </summary> /// </summary>
internal Stream ClientStream { get; set; } internal Stream ClientStream { get; set; }
/// <summary> /// <summary>
/// Used to read line by line from server /// Used to read line by line from client
/// </summary> /// </summary>
internal CustomBinaryReader ClientStreamReader { get; set; } internal CustomBinaryReader ClientStreamReader { get; set; }
/// <summary> /// <summary>
/// used to write line by line to server /// used to write line by line to client
/// </summary> /// </summary>
internal StreamWriter ClientStreamWriter { get; set; } internal StreamWriter ClientStreamWriter { get; set; }
......
...@@ -198,7 +198,7 @@ namespace Titanium.Web.Proxy ...@@ -198,7 +198,7 @@ namespace Titanium.Web.Proxy
} }
var args = new SessionEventArgs(); var args = new SessionEventArgs();
args.TcpClient = client; args.ProxyClient.TcpClient = client;
try try
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment