]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
From: Joe Ramey <ramey@csc.ti.com>
authorwessels <>
Sat, 2 Nov 1996 04:51:16 +0000 (04:51 +0000)
committerwessels <>
Sat, 2 Nov 1996 04:51:16 +0000 (04:51 +0000)
Here's another bugfix for the squid-1.1beta12 base64 routine.
The problem this time was that if the length of the encoded string was
a multiple of four, the conversion wouldn't null terminate the string
and so garbage would be appended.  here's a fix:

lib/base64.c

index 6e6c704e349204d8dc74236269243b25c0aa3548..bbde7380b4756832b942831df292ad5e185a6ed2 100644 (file)
@@ -60,6 +60,6 @@ base64_decode(char *p)
            val = c = 0;
        }
     }
-
+    *d = 0;
     return *result ? result : NULL;
 }