mirror of
https://github.com/proxytunnel/proxytunnel.git
synced 2026-01-23 02:34:59 +00:00
Improved verbose output, easier for the eyes
git-svn-id: https://proxytunnel.svn.sourceforge.net/svnroot/proxytunnel/trunk/proxytunnel@175 bc163920-b10d-0410-b2c5-a5491ca2ceef
This commit is contained in:
parent
f2f3d3811b
commit
24b37ca6c6
3 changed files with 9 additions and 8 deletions
12
http.c
12
http.c
|
|
@ -102,7 +102,7 @@ void print_line_prefix(char *buf, char *prefix)
|
|||
buf = strdup(buf);
|
||||
char *cur = strtok(buf, "\r\n");
|
||||
while ( cur != NULL) {
|
||||
message( "%s %s\n", prefix, cur );
|
||||
message( "%s%s\n", prefix, cur );
|
||||
cur = strtok(NULL, "\r\n");
|
||||
}
|
||||
}
|
||||
|
|
@ -136,13 +136,13 @@ void proxy_protocol(PTSTREAM *pts)
|
|||
if (args_info.remproxy_given )
|
||||
{
|
||||
if( args_info.verbose_flag )
|
||||
message( "Tunneling to %s (remote proxy)\n", args_info.remproxy_arg );
|
||||
message( "\nTunneling to %s (remote proxy)\n", args_info.remproxy_arg );
|
||||
sprintf( buf, "CONNECT %s HTTP/1.0\r\n", args_info.remproxy_arg );
|
||||
}
|
||||
else
|
||||
{
|
||||
if( args_info.verbose_flag )
|
||||
message( "Tunneling to %s (destination)\n", args_info.dest_arg );
|
||||
message( "\nTunneling to %s (destination)\n", args_info.dest_arg );
|
||||
sprintf( buf, "CONNECT %s HTTP/1.0\r\n", args_info.dest_arg );
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +178,7 @@ void proxy_protocol(PTSTREAM *pts)
|
|||
*/
|
||||
if( args_info.verbose_flag ) {
|
||||
message( "Connect string sent to local proxy:\n");
|
||||
print_line_prefix(buf, "->");
|
||||
print_line_prefix(buf, " đ» ");
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
@ -205,7 +205,7 @@ void proxy_protocol(PTSTREAM *pts)
|
|||
while ( strcmp( buf, "\r\n" ) != 0 ) readline(pts);
|
||||
|
||||
if( args_info.verbose_flag )
|
||||
message( "Tunneling to %s (destination)\n", args_info.dest_arg );
|
||||
message( "\nTunneling to %s (destination)\n", args_info.dest_arg );
|
||||
sprintf( buf, "CONNECT %s HTTP/1.0\r\n", args_info.dest_arg);
|
||||
|
||||
/*
|
||||
|
|
@ -220,7 +220,7 @@ void proxy_protocol(PTSTREAM *pts)
|
|||
*/
|
||||
if( args_info.verbose_flag ) {
|
||||
message( "Connect string sent to remote proxy:\n");
|
||||
print_line_prefix(buf, "->");
|
||||
print_line_prefix(buf, " » ");
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue