Re: svn commit: r1916332 - /apr/apr/trunk/test/testescape.c

Joe Orton <[email protected]>
Newsgroups gmane.comp.apache.apr.devel
Organization Registered in England and Wales under Company Registration No. 03798903 Directors: Michael Cunningham (US), Michael O'Neill (Ireland), Paul Argiry (US)
Message-ID <[email protected]>
On Fri, Mar 15, 2024 at 10:26:27AM -0000, [email protected] wrote:
> Author: ylavic
> Date: Fri Mar 15 10:26:27 2024
> New Revision: 1916332
> 
> URL: http://svn.apache.org/viewvc?rev=1916332&view=rev
> Log:
> testescape: missing ';' in entity escaping.

The test now fails... did you intend to commit the fix too, something 
like this?

Index: encoding/apr_escape.c
===================================================================
--- encoding/apr_escape.c	(revision 1916388)
+++ encoding/apr_escape.c	(working copy)
@@ -571,7 +571,7 @@
                     found = 1;
                 }
                 else if (toasc && !apr_isascii(c)) {
-                    int offset = apr_snprintf((char *) d, 6, "&#%3.3d;", c);
+                    int offset = apr_snprintf((char *) d, 7, "&#%3.3d;", c);
                     size += offset;
                     d += offset;
                     found = 1;
@@ -614,7 +614,7 @@
                 }
                 else if (toasc && !apr_isascii(c)) {
                     char buf[8];
-                    size += apr_snprintf(buf, 6, "&#%3.3d;", c);
+                    size += apr_snprintf(buf, 7, "&#%3.3d;", c);
                     found = 1;
                 }
                 else {
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.