From 2a226d898f07e72da4e8f8f9fd2c476d624137b0 Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Wed, 16 Sep 2009 20:41:32 +1200 Subject: [PATCH] Prevent squidclient sending two Accept: headers --- tools/squidclient.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/squidclient.cc b/tools/squidclient.cc index 999648cecd..547dfe093d 100644 --- a/tools/squidclient.cc +++ b/tools/squidclient.cc @@ -436,16 +436,16 @@ main(int argc, char *argv[]) /* HTTP/1.0 may need keep-alive */ if (strcmp(version, "1.0") == 0) { if (keep_alive) { - if (strchr(url, ':')) + if (strchr(url, ':')) { snprintf(buf, BUFSIZ, "Proxy-Connection: keep-alive\r\n"); - else + strcat(msg, buf); + } else strcat(msg, "Connection: keep-alive\r\n"); } } else { if (!keep_alive) strcat(msg, "Connection: close\r\n"); } - strcat(msg, buf); strcat(msg, extra_hdrs); strcat(msg, "\r\n"); -- 2.47.3