https://bz.apache.org/bugzilla/show_bug.cgi?id=69275

            Bug ID: 69275
           Summary: Incorrect define of strchr, strrchr, strstr
           Product: Apache httpd-2
           Version: 2.4.62
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Core
          Assignee: bugs@httpd.apache.org
          Reporter: marc.st...@approach-cyber.com
  Target Milestone: ---

When AP_DEBUG is defined, strchr, strrchr & strstr are mapped to ap_strchr,
ap_strrchr, & ap_strstr. This gives a huge number of warnings all over the
place when calling one of these standard functions with a 'const char *'.
Example:
 const char *s1;
 char *s2
 [...]
 if (strstr(s1, s2) == 0) ...

As these standard functions use a 'const char *' in their prototype, we should
map them to the '_c' version:
 # define strchr(s, c)  ap_strchr_c(s,c)
 # define strrchr(s, c) ap_strrchr_c(s,c)
 # define strstr(s, c)  ap_strstr_c(s,c)

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscr...@httpd.apache.org
For additional commands, e-mail: bugs-h...@httpd.apache.org

Reply via email to