From 54b16b18dd5ee116df4eb5d830ddb8707c38e425 Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Sun, 30 Jul 2017 16:11:56 +0200 Subject: [PATCH] Set status.proxy_passed early for Proxy = exec. --- src/net_socket.c | 1 + src/proxy.c | 6 ++---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/net_socket.c b/src/net_socket.c index 284bab7..60dd81d 100644 --- a/src/net_socket.c +++ b/src/net_socket.c @@ -442,6 +442,7 @@ connect: if(!proxytype) { c->socket = socket(c->address.sa.sa_family, SOCK_STREAM, IPPROTO_TCP); } else if(proxytype == PROXY_EXEC) { + c->status.proxy_passed = true; do_outgoing_pipe(c, proxyhost); } else { proxyai = str2addrinfo(proxyhost, proxyport, SOCK_STREAM); diff --git a/src/proxy.c b/src/proxy.c index f7c2560..ba48218 100644 --- a/src/proxy.c +++ b/src/proxy.c @@ -1,6 +1,6 @@ /* proxy.c -- Proxy handling functions. - Copyright (C) 2015-2016 Guus Sliepen + Copyright (C) 2015-2017 Guus Sliepen This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -174,9 +174,7 @@ bool send_proxyrequest(connection_t *c) { } case PROXY_EXEC: - c->status.proxy_passed = true; - send_id(c); - return true; + abort(); default: logger(LOG_ERR, "Unknown proxy type"); -- 2.25.1