]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
- fixed a clang error when dividing sizeof(T1i[]) / sizeof(T2).
authorStefan Eissing <icing@apache.org>
Mon, 1 Feb 2021 09:01:22 +0000 (09:01 +0000)
committerStefan Eissing <icing@apache.org>
Mon, 1 Feb 2021 09:01:22 +0000 (09:01 +0000)
   these modern compilers have no respect for code from 2009.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1886096 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/simple/simple_run.c

index a61bfa66bc1f4101fab93277379e8759fbf728b4..102eed55e2d457cf5ff9e47275e321b738c23511 100644 (file)
@@ -260,7 +260,7 @@ static int simple_setup_pollcb(simple_core_t * sc)
     apr_status_t rv;
     int good_methods[] = {APR_POLLSET_KQUEUE, APR_POLLSET_PORT, APR_POLLSET_EPOLL};
 
-    for (i = 0; i < sizeof(good_methods) / sizeof(void*); i++) {
+    for (i = 0; i < sizeof(good_methods) / sizeof(good_methods[0]); i++) {
         /* pqXXXXX: make size of pollcb configrable or dynamic */
         rv = apr_pollcb_create_ex(&sc->pollcb, 512,
                                   sc->pool, APR_POLLSET_NODEFAULT, good_methods[i]);