Summary: | Code clean up (apr_strings.c) | ||
---|---|---|---|
Product: | APR | Reporter: | Christophe JAILLET <christophe.jaillet> |
Component: | APR | Assignee: | Apache Portable Runtime bugs mailinglist <bugs> |
Status: | RESOLVED WONTFIX | ||
Severity: | enhancement | Keywords: | PatchAvailable |
Priority: | P2 | ||
Version: | HEAD | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Windows 2000 | ||
Attachments: | Proposed patch |
This is only true in trunk. There the change was introduced by Jeff in r1089438: change apr_palloc+memcpy to apr_pmemdup PR: 47776 Submitted by: Boya Sun <boya.sun case.edu> Useless |
Created attachment 28081 [details] Proposed patch Hi, in strings/apr_strings.c, most functions allocate its own memory when needed except 'apr_pstrdup' which actually call 'apr_pmemdup' for that. This patch inlines this call in order to be more consistent with-in the code. This also removes a small calling overhead in case the compiler does not inline the function by itself. Hoping this helps.