Re: Squid's Error Msgs

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Sun, 25 Oct 1998 15:32:43 +0100

David J N Begley wrote:

> Just curious - but how would removing Squid's name and version
> number from error templates violate the GPL?

You are right. The notice is not truly a copyright message and
removing it is not a GPL violation.

> There should be some way of including Squid's name and version
> in the error pages, if for no reason other than making diagnosis
> easier; but perhaps it should be up to the template writer as to
> where/how this appears (in a META tag, in the body of the message,
> formatted differently, whatever).

If you remove the line I indicated then you can add the message
anywhere you like, in any style you prefer.
  %T == time
  %h == visible host name
  %s == squid version

I understand that some people needs to change the look or language
of the signature, but we are not willing to allow people to
completely remove the Squid signature by simply changing the
template.

As a compromize i propose the following code change:
Add the default signature unless %s is used in the template.
[patch attached]

---
Henrik Nordstrom
Spare time squid hacker
    [ Part 2: "Attached Text" ]
Index: squid/src/errorpage.c
diff -u squid/src/errorpage.c:1.1.1.19 squid/src/errorpage.c:1.1.1.19.8.1
--- squid/src/errorpage.c:1.1.1.19	Thu Sep 24 00:19:32 1998
+++ squid/src/errorpage.c	Sun Oct 25 15:12:47 1998
@@ -169,7 +169,8 @@
 	text = NULL;
     }
     file_close(fd);
-    strcat(text, "%S");		/* add signature */
+    if (strstr(text,"%s") == NULL)
+	strcat(text, "%S");		/* add signature */
     return text;
 }
 
Received on Tue Jul 29 2003 - 13:15:54 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:11:57 MST