-
Notifications
You must be signed in to change notification settings - Fork 594
UCS/SOCKET: simple input parameter naming fix #11859
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -461,7 +461,7 @@ ucs_status_t ucs_socket_set_buffer_size(int fd, size_t sockopt_sndbuf, | |||||||||
| } | ||||||||||
|
|
||||||||||
| ucs_status_t ucs_socket_server_init(const struct sockaddr *saddr, socklen_t socklen, | ||||||||||
| int backlog, int silent_err_in_use, | ||||||||||
| int backlog, int silent_bind, | ||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Inconsistent parameter name. The header
Suggested change
Pls also rename the use on the
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What are talking about? I do just that! There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. the header was renamed to |
||||||||||
| int reuse_addr, int *listen_fd) | ||||||||||
| { | ||||||||||
| int so_reuse_optval = 1; | ||||||||||
|
|
@@ -493,7 +493,7 @@ ucs_status_t ucs_socket_server_init(const struct sockaddr *saddr, socklen_t sock | |||||||||
|
|
||||||||||
| ret = bind(fd, saddr, socklen); | ||||||||||
| if (ret < 0) { | ||||||||||
| if ((errno == EADDRINUSE) && silent_err_in_use) { | ||||||||||
| if ((errno == EADDRINUSE) && silent_bind) { | ||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Inconsistent parameter name; rename the use on the
Suggested change
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You are being silly, mr. Robot There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
complete the rename in the function body as well. |
||||||||||
| bind_log_level = UCS_LOG_LEVEL_DEBUG; | ||||||||||
| } else { | ||||||||||
| bind_log_level = UCS_LOG_LEVEL_ERROR; | ||||||||||
|
|
||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor:
silent_bindreads broader than the behavior — only theEADDRINUSEcase is silenced. Fine given the doc comment clarifies it, just flagging.