Skip to content
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

Avoid usage of PATH_MAX not available on hurd #208

Closed
wants to merge 1 commit into from

Conversation

cgzones
Copy link
Contributor

@cgzones cgzones commented Sep 15, 2023

No description provided.

@cmouse
Copy link
Contributor

cmouse commented Sep 15, 2023

how about

#ifndef PATH_MAX
#define PATH_MAX 4096
#endif

in compat.h?

@cgzones
Copy link
Contributor Author

cgzones commented Sep 15, 2023

PATH_MAX is not guaranteed by to be a compile time constant, see https://pubs.opengroup.org/onlinepubs/009696699/basedefs/limits.h.html.
So it might be best for portability to use it as little as possible, e.g. not export it via compat.h. The current only other usage is in src/lib-storage/mailbox-list.h (falling back to 4096 as well).

@cmouse
Copy link
Contributor

cmouse commented Sep 25, 2023

merged as e459141

@cmouse cmouse closed this Sep 25, 2023
@cgzones cgzones deleted the hurd branch September 26, 2023 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants