Klaus Demo nginx / 1f3dea2
Fixed the NGX_UNIX_ADDRSTRLEN macro. Ruslan Ermilov 4 years ago
1 changed file(s) with 3 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
1616 #define NGX_INET6_ADDRSTRLEN \
1717 (sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255") - 1)
1818 #define NGX_UNIX_ADDRSTRLEN \
19 (sizeof(struct sockaddr_un) - offsetof(struct sockaddr_un, sun_path))
19 (sizeof("unix:") - 1 + \
20 sizeof(struct sockaddr_un) - offsetof(struct sockaddr_un, sun_path))
2021
2122 #if (NGX_HAVE_UNIX_DOMAIN)
22 #define NGX_SOCKADDR_STRLEN (sizeof("unix:") - 1 + NGX_UNIX_ADDRSTRLEN)
23 #define NGX_SOCKADDR_STRLEN NGX_UNIX_ADDRSTRLEN
2324 #elif (NGX_HAVE_INET6)
2425 #define NGX_SOCKADDR_STRLEN (NGX_INET6_ADDRSTRLEN + sizeof("[]:65535") - 1)
2526 #else