You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2011/08/20 15:06:27 UTC

DO NOT REPLY [Bug 51699] New: Code clean up (use apr_pstrcat where appropriate)

https://issues.apache.org/bugzilla/show_bug.cgi?id=51699

             Bug #: 51699
           Summary: Code clean up (use apr_pstrcat where appropriate)
           Product: Apache httpd-2
           Version: 2.3-HEAD
          Platform: PC
        OS/Version: Windows 2000
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: All
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: christophe.jaillet@wanadoo.fr
    Classification: Unclassified


Created attachment 27418
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=27418
Proposed patch

Hi,

I've spotted two places where we could use 'apr_pstrcat' instead of the hand
coded equivalent sequence.

IMO, this improve a lot readability of the code.

However, the proposed patch is a little slower than the original code because
we need to compute twice the length of the string (once in apr_pstrcat and one
with a strlen I have to add)
So, if you think that there is no need to apply this patch, just close the
report.

As i'm still enable to compule httpd on my machine, the patch is untested and
provided as-is.


Best regards,
Christophe JAILLET

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51699] Code clean up (use apr_pstrcat where appropriate)

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51699

Christophe JAILLET <ch...@wanadoo.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |PatchAvailable

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


DO NOT REPLY [Bug 51699] Code clean up (use apr_pstrcat where appropriate)

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=51699

Stefan Fritsch <sf...@sfritsch.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #1 from Stefan Fritsch <sf...@sfritsch.de> 2011-08-20 18:29:56 UTC ---
Committed as r1159896 with some tweaks (the mod_include code could be
simplified even more with apr_brigade_putstrs).

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org