Skip to content

Fix OpenBSD build #1852

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

Closed
wants to merge 3 commits into from
Closed

Fix OpenBSD build #1852

wants to merge 3 commits into from

Conversation

victorhora
Copy link
Contributor

OpenBSD build was breaking due to the lack of wordexp.h. Patch fixes the build by using glob.h when building on OpenBSD. Should fix #1841.

@victorhora
Copy link
Contributor Author

victorhora commented Jul 26, 2018

Maybe we should consider using glob.h by default on all platforms as a matter of best practice due to security concerns with wordexp. That being said, according to the docs, glob.h has "No tilde expansion or parameter substitution is done; if you want these, use wordexp(3)."

GLOB_TILDE flag could be used for tilde expansion, but as this would require further changes I refrained from doing this at the moment.

@victorhora
Copy link
Contributor Author

Wondering if something like:

Include test-cases/data/config_example2*.*

Would be a valid test scenario to prove that expandEnv() is also functionally correct when using glob.

Thoughts?

@zimmerle
Copy link
Contributor

Merged! Thanks!

@zimmerle zimmerle closed this Sep 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OpenBSD doesn't have the header wordexp.h
2 participants