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

Fix build failure when using UNICODE / _UNICODE on Windows #149

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

walbourn
Copy link

@walbourn walbourn commented Feb 5, 2023

Per the UTF-8 Everywhere Manifesto, it's best to not rely on the legacy ANSI .vs UNICODE macros for Win32 functions that take strings. Since you explicitly use a std::string for the call to InetPton you should explicitly use the InetPtonA method.

This causes problems when trying to build your library using vcpkg manager when the setup adds the recommended UNICODE _UNICODE defines.

@github-actions github-actions bot added the PR: Community Contribution 👑 Community Contribution PR's label Feb 5, 2023
@jellespijker jellespijker self-assigned this Feb 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: Community Contribution 👑 Community Contribution PR's
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants