Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Listen options inc FREEBIND support #114

Closed
wants to merge 1 commit into from

Conversation

notroj
Copy link
Collaborator

@notroj notroj commented Apr 20, 2020

Add AP_LISTEN_SPECIFIC_ERRORS, AP_LISTEN_FREEBIND as flags.
Add ListenFree directive, setting AP_LISTEN_FREEBIND flag.
Create socket with APR_SO_FREEBIND set if flag used.

Submitted by: jorton, Lubos Uhliarik
PR: 61865

@notroj notroj force-pushed the listenfree branch 2 times, most recently from 58d0cbf to abd7c5b Compare April 21, 2020 11:23
@notroj notroj changed the title Convert ap_listen_rec.use_specific_errors field to flags. Add Listen options inc FREEBIND support Apr 21, 2020
socket options.

Reimplement "use_specific_errors" listener flag under generic
ap_listen_rec flags field to hold both these options.

* include/ap_listen.h: Add AP_LISTEN_* flags.
  (ap_listen_rec): Rename use_specific_errors to flags.

* server/listen.c (make_sock): Set APR_SO_FREEBIND if
  AP_LISTEN_FREEBIND flag is set on listener; set APR_SO_REUSEPORT
  unconditionally if AP_LISTEN_REUSEPORT is set.
  (alloc_listener): Take flags argument.
  (ap_setup_listeners): Set AP_LISTEN_SPECIFIC_ERRORS flag here.
  (ap_set_listener): Parse optional options=... argument, catch
  typos and fail if protocol name contains a "=".
  (ap_duplicate_listeners): Duplicate flags.

Submitted by: jkaluza, Lubos Uhliarik <luhliari redhat.com>, jorton
PR: 61865
@asfgit asfgit closed this in a42f369 Apr 23, 2020
@notroj notroj deleted the listenfree branch April 23, 2020 08:33
notroj added a commit to notroj/httpd that referenced this pull request Jun 23, 2020
socket options.

Reimplement "use_specific_errors" listener flag under generic
ap_listen_rec flags field holding all listener-specific options.

* include/ap_listen.h: Add AP_LISTEN_* flags.
  (ap_listen_rec): Rename use_specific_errors to flags.

* server/listen.c (make_sock): Set APR_SO_FREEBIND if
  AP_LISTEN_FREEBIND flag is set on listener; set APR_SO_REUSEPORT
  unconditionally if AP_LISTEN_REUSEPORT is set.
  (alloc_listener): Take flags argument.
  (ap_setup_listeners): Set AP_LISTEN_SPECIFIC_ERRORS flag here.
  (ap_set_listener): Parse optional options=... argument, catch
  typos and fail if protocol name contains a "=".
  (ap_duplicate_listeners): Duplicate flags.

Submitted by: jkaluza, Lubos Uhliarik <luhliari redhat.com>, jorton
PR: 61865
Github: closes apache#114


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1876865 13f79535-47bb-0310-9956-ffa450edef68
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant