diff options
author | Max Romanov <max.romanov@nginx.com> | 2021-12-01 18:06:38 +0300 |
---|---|---|
committer | Max Romanov <max.romanov@nginx.com> | 2021-12-01 18:06:38 +0300 |
commit | 2d6e926a1def94e4def5b8f8da73078685626ff4 (patch) | |
tree | 2986a33cf814de81f4006f08e33b744390858594 | |
parent | 97e61aad736da5fe1ad136a1d3055e16698f7d2b (diff) | |
download | unit-2d6e926a1def94e4def5b8f8da73078685626ff4.tar.gz unit-2d6e926a1def94e4def5b8f8da73078685626ff4.tar.bz2 |
Disabling SCM_CREDS usage on DragonFly BSD.
DragonFly BSD supports SCM_CREDS and SCM_RIGHTS, but only the first control
message is passed correctly while the second one isn't processed by the kernel.
This closes #599 issue on GitHub.
-rw-r--r-- | auto/sockets | 62 | ||||
-rw-r--r-- | docs/changes.xml | 6 |
2 files changed, 38 insertions, 30 deletions
diff --git a/auto/sockets b/auto/sockets index 1b6b4368..e6ef326d 100644 --- a/auto/sockets +++ b/auto/sockets @@ -166,51 +166,53 @@ if [ $nxt_found = no ]; then fi -nxt_feature="sockopt SO_PASSCRED" -nxt_feature_name=NXT_HAVE_SOCKOPT_SO_PASSCRED -nxt_feature_run= -nxt_feature_incs= -nxt_feature_libs= -nxt_feature_test="#define _GNU_SOURCE - #include <sys/socket.h> +if [ $NXT_SYSTEM != DragonFly ]; then + nxt_feature="sockopt SO_PASSCRED" + nxt_feature_name=NXT_HAVE_SOCKOPT_SO_PASSCRED + nxt_feature_run= + nxt_feature_incs= + nxt_feature_libs= + nxt_feature_test="#define _GNU_SOURCE + #include <sys/socket.h> - int main() { - return SO_PASSCRED == 0; - }" -. auto/feature + int main() { + return SO_PASSCRED == 0; + }" + . auto/feature -if [ $nxt_found = yes ]; then - nxt_feature="struct ucred" - nxt_feature_name=NXT_HAVE_UCRED + if [ $nxt_found = yes ]; then + nxt_feature="struct ucred" + nxt_feature_name=NXT_HAVE_UCRED + nxt_feature_run= + nxt_feature_incs= + nxt_feature_libs= + nxt_feature_test="#define _GNU_SOURCE + #include <sys/socket.h> + #include <sys/un.h> + + int main() { + return sizeof(struct ucred); + }" + . auto/feature + fi + + + nxt_feature="struct cmsgcred" + nxt_feature_name=NXT_HAVE_MSGHDR_CMSGCRED nxt_feature_run= nxt_feature_incs= nxt_feature_libs= nxt_feature_test="#define _GNU_SOURCE #include <sys/socket.h> - #include <sys/un.h> int main() { - return sizeof(struct ucred); + return sizeof(struct cmsgcred); }" . auto/feature fi -nxt_feature="struct cmsgcred" -nxt_feature_name=NXT_HAVE_MSGHDR_CMSGCRED -nxt_feature_run= -nxt_feature_incs= -nxt_feature_libs= -nxt_feature_test="#define _GNU_SOURCE - #include <sys/socket.h> - - int main() { - return sizeof(struct cmsgcred); - }" -. auto/feature - - nxt_feature="sys/filio.h" nxt_feature_name=NXT_HAVE_SYS_FILIO_H nxt_feature_run= diff --git a/docs/changes.xml b/docs/changes.xml index 2bbec889..7460aa65 100644 --- a/docs/changes.xml +++ b/docs/changes.xml @@ -59,6 +59,12 @@ appeared in 1.26.0. </para> </change> +<change type="bugfix"> +<para> +fatal errors on DragonFly BSD; the bug had appeared in 1.26.0. +</para> +</change> + </changes> |