New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
httpnEncode64 function in addition to httpEncode64 #860
Comments
CUPS.org User: mike OK, we won't accept this patch as-is, as it does not conform to the CMP coding standards (wrong indentation, no documentation added to the top of the http.c file, wrong function name prefix). I'm thinking that we want to roll this into the new httpEncode64_2() function in 1.1.21 which adds a length parameter for the output buffer. It would be trivial to add a length parameter for the input buffer as well, since 1.1.21 hasn't been officially released. The same will be true for the httpDecode64_2() function, so that it will be possible to decode arbitrary binary data as well... |
CUPS.org User: mike Please let me know if you run into any problems with the patch... |
CUPS.org User: mike Fixed in CVS - the anonymous CVS repository will be updated at midnight EST. |
"cups-1.1.21-httpnEncode64.patch": --- cups-1.1.21rc1/cups/http.c~ 2004-08-17 10:26:39.705383344 -0400
+/*
+char * /* O - Encoded string /
in ++;
*outptr ++ = base64[in[0] & 63];
*outptr = '\0';
/*
|
"str860.patch": Index: http.cRCS file: /development/cvs/cups/cups/http.c,v
@@ -353,7 +357,10 @@
httpInitialize();
-char * /* O - Decoded string /
+/*
return (out); @@ -1772,12 +1824,27 @@
-char * /* O - Encoded string /
+/*
+/**** New in CUPS 1.1.21 ****/
|
Version: 1.1.21rc1
CUPS.org User: twaugh.redhat
(Colin Walters says:)
The CUPS httpEncode64 function isn't all that useful for what I'm doing,
since it only works on NULL-terminated strings, and I need to pass in
binary data. Here's a patch which adds a new httpnEncode64 function,
and defines httpEncode64 in terms of it.
The text was updated successfully, but these errors were encountered: