Skip to content

replace select with poll in nopoll#36

Open
bill1600 wants to merge 3 commits intoxmidt-org:nopoll_yoctofrom
bill1600:nopoll_poll
Open

replace select with poll in nopoll#36
bill1600 wants to merge 3 commits intoxmidt-org:nopoll_yoctofrom
bill1600:nopoll_poll

Conversation

@bill1600
Copy link

Replace select with poll in nopoll.

@CLAassistant
Copy link

CLAassistant commented Jul 10, 2019

CLA assistant check
All committers have signed the CLA.

* @param fd_group The fd group to be deallocated.
*/
void nopoll_io_wait_select_destroy (noPollCtx * ctx, noPollPtr fd_group)
void nopoll_io_wait_select_destroy (noPollCtx * ctx, noPollPtr __fd_group)
Copy link
Collaborator

Choose a reason for hiding this comment

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

variables with double underscores are generally reserved by libc as private namespace.

Copy link
Author

Choose a reason for hiding this comment

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

Numerous nopoll modules violate this rule, with numerous function names, parameter names, and variable names that start with double underscores.
So the question for us would be how to deal with software we didn't write that has already been written to a standard we don't agree with.
In this specific case, I thought it was best to just conform to the naming convention already being used in this module, nopoll_io.c.

#include <arpa/inet.h>
#include <sys/select.h>
/* #include <sys/select.h> */
#define NOPOLL_HAVE_POLL 1
Copy link
Collaborator

Choose a reason for hiding this comment

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

this should be automatically detected with autoconf if not then we should add the test to configure script.

Copy link
Author

Choose a reason for hiding this comment

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

I will try without the #define.

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.

3 participants