Skip to content

Fix max sockaddr struct size on OpenBSD#40454

Closed
brad0 wants to merge 1 commit intogrpc:masterfrom
brad0:max_struct_openbsd
Closed

Fix max sockaddr struct size on OpenBSD#40454
brad0 wants to merge 1 commit intogrpc:masterfrom
brad0:max_struct_openbsd

Conversation

@brad0
Copy link
Copy Markdown
Contributor

@brad0 brad0 commented Aug 17, 2025

No description provided.

@brad0
Copy link
Copy Markdown
Contributor Author

brad0 commented Aug 30, 2025

Ping.

@brad0
Copy link
Copy Markdown
Contributor Author

brad0 commented Sep 21, 2025

Ping.

1 similar comment
@brad0
Copy link
Copy Markdown
Contributor Author

brad0 commented Sep 30, 2025

Ping.

@markdroth markdroth requested review from markdroth and removed request for eugeneo October 7, 2025 04:28
@brad0
Copy link
Copy Markdown
Contributor Author

brad0 commented Oct 20, 2025

@markdroth Ping.

@markdroth markdroth assigned murgatroid99 and unassigned eugeneo Oct 28, 2025
@brad0
Copy link
Copy Markdown
Contributor Author

brad0 commented Nov 8, 2025

What magic incantations do I need to do to get this reviewed?

Copy link
Copy Markdown
Member

@murgatroid99 murgatroid99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Our standard for handling platform differences like this is to handle those checks in port_platform.h. A constant should be defined there, and these files should just reference it.

@brad0
Copy link
Copy Markdown
Contributor Author

brad0 commented Feb 25, 2026

Our standard for handling platform differences like this is to handle those checks in port_platform.h. A constant should be defined there, and these files should just reference it.

Thanks. That makes a lot more sense and is cleaner.

Comment thread include/grpc/support/port_platform.h Outdated
#endif
#endif

#ifndef GRPC_MAX_SOCKADDR_SIZE
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be more consistent with the rest of the file to write the following here, and remove the other change:

#ifdef GPR_OPENBSD
#define GRPC_MAX_SOCKADDR_SIZE 256
#else
#define GRPC_MAX_SOCKADDR_SIZE 128
#endif

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, done.

@murgatroid99 murgatroid99 added the release notes: yes Indicates if PR needs to be in release notes label Feb 25, 2026
Move the definition of GRPC_MAX_SOCKADDR_SIZE over to port_platform.h
and override the value for OpenBSD.
@brad0 brad0 deleted the max_struct_openbsd branch February 27, 2026 19:43
Zgoda91 pushed a commit to Zgoda91/grpc that referenced this pull request Mar 22, 2026
Closes grpc#40454

COPYBARA_INTEGRATE_REVIEW=grpc#40454 from brad0:max_struct_openbsd a29f029
PiperOrigin-RevId: 876346213
asheshvidyut pushed a commit to asheshvidyut/grpc that referenced this pull request Mar 26, 2026
Closes grpc#40454

COPYBARA_INTEGRATE_REVIEW=grpc#40454 from brad0:max_struct_openbsd a29f029
PiperOrigin-RevId: 876346213
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bloat/none lang/core release notes: yes Indicates if PR needs to be in release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants