Skip to content
This repository was archived by the owner on May 27, 2026. It is now read-only.

C++ include netinet/in.h and sys/socket.h on non-Windows#1389

Draft
delphij wants to merge 1 commit into
bufbuild:mainfrom
delphij:main
Draft

C++ include netinet/in.h and sys/socket.h on non-Windows#1389
delphij wants to merge 1 commit into
bufbuild:mainfrom
delphij:main

Conversation

@delphij
Copy link
Copy Markdown

@delphij delphij commented May 7, 2026

arpa/inet.h does not guarantee that socket types (struct sockaddr, socklen_t, etc.) are defined on all POSIX platforms. FreeBSD in particular requires netinet/in.h and sys/socket.h to be included explicitly. Add both under the existing !_WIN32 guard.

arpa/inet.h does not guarantee that socket types (struct sockaddr,
socklen_t, etc.) are defined on all POSIX platforms.  FreeBSD in
particular requires netinet/in.h and sys/socket.h to be included
explicitly.  Add both under the existing !_WIN32 guard.
@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@delphij delphij marked this pull request as draft May 7, 2026 08:27
@rodaine rodaine changed the title validate.h: include netinet/in.h and sys/socket.h on non-Windows C++ include netinet/in.h and sys/socket.h on non-Windows May 27, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants