Commit 8bc50e76 authored by justcoding121's avatar justcoding121

Fix bug in dispose param

parent 3ef9595d
......@@ -31,7 +31,7 @@ namespace Titanium.Web.Proxy.EventArguments
}
/// <summary>
/// Holds a reference to server connection
/// Holds a reference to client
/// </summary>
internal ProxyClient ProxyClient { get; set; }
......@@ -41,7 +41,7 @@ namespace Titanium.Web.Proxy.EventArguments
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>
/// A web session corresponding to a single request/response sequence
......@@ -49,11 +49,6 @@ namespace Titanium.Web.Proxy.EventArguments
/// </summary>
public HttpWebClient WebSession { get; set; }
/// <summary>
/// Reference to client connection
/// </summary>
internal TcpClient TcpClient { get; set; }
/// <summary>
/// implement any cleanup here
......
......@@ -11,6 +11,9 @@ namespace Titanium.Web.Proxy.Http
{
public class HttpWebClient
{
/// <summary>
/// Connection to server
/// </summary>
internal TcpConnection ServerConnection { get; set; }
public Request Request { get; set; }
......
......@@ -10,22 +10,22 @@ namespace Titanium.Web.Proxy.Network
public class ProxyClient
{
/// <summary>
/// TcpClient used to communicate with server
/// TcpClient used to communicate with client
/// </summary>
internal TcpClient TcpClient { get; set; }
/// <summary>
/// holds the stream to server
/// holds the stream to client
/// </summary>
internal Stream ClientStream { get; set; }
/// <summary>
/// Used to read line by line from server
/// Used to read line by line from client
/// </summary>
internal CustomBinaryReader ClientStreamReader { get; set; }
/// <summary>
/// used to write line by line to server
/// used to write line by line to client
/// </summary>
internal StreamWriter ClientStreamWriter { get; set; }
......
......@@ -198,7 +198,7 @@ namespace Titanium.Web.Proxy
}
var args = new SessionEventArgs();
args.TcpClient = client;
args.ProxyClient.TcpClient = client;
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