-
Notifications
You must be signed in to change notification settings - Fork 378
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
build: Keep an autoconf check for pthread_setname_np() #4103
base: master
Are you sure you want to change the base?
Conversation
This reverts commit 41cdd27. Even though everybody has a pthread_setname_np(3), they are different and not portable by definition. The safeguards should be preserved since THR_SetName() will at least allow a panic to get the thread name.
We can rely on pthread_setname_np() for all the platforms we care about. The nested preprocessor conditions for pthread_setname_np are indented to improve readability. Better diff with the --ignore-all-space option.
First apologies for confusing everybody with a sign-error on the underscore There is no reason to retain this check because all relevant platforms today have pthread_setname_np() and if somebody wants to port varnish to a new platform, they will have to provide a pthread_setname_np() function. Please also note that the "_np" suffix literally means "POSIX is stuck in the 1990'ies where some people ran VMS", it doesnt mean that all contemporary platforms do not have it. |
FTR, I just hit this on a not-so-recent SmartOS
|
The |
FYI: Just hit this on OpenBSD. |
bugwash: @walid-git to resolve conflicts and merge |
It is not portable by definition, so we should keep the guards.