-
Notifications
You must be signed in to change notification settings - Fork 9.2k
Callback function passed to EnumFontFamiliesExW uses wrong signature #889
Copy link
Copy link
Open
Labels
Area-CodeHealthIssues related to code cleanliness, linting, rules, warnings, errors, static analysis, etc.Issues related to code cleanliness, linting, rules, warnings, errors, static analysis, etc.Help WantedWe encourage anyone to jump in on these.We encourage anyone to jump in on these.Issue-BugIt either shouldn't be doing this or needs an investigation.It either shouldn't be doing this or needs an investigation.Product-ConhostFor issues in the Console codebaseFor issues in the Console codebase
Milestone
Metadata
Metadata
Assignees
Labels
Area-CodeHealthIssues related to code cleanliness, linting, rules, warnings, errors, static analysis, etc.Issues related to code cleanliness, linting, rules, warnings, errors, static analysis, etc.Help WantedWe encourage anyone to jump in on these.We encourage anyone to jump in on these.Issue-BugIt either shouldn't be doing this or needs an investigation.It either shouldn't be doing this or needs an investigation.Product-ConhostFor issues in the Console codebaseFor issues in the Console codebase
Example callback function used with
EnumFontFamiliesExW:But
FONTENUMPROCas expected byEnumFontFamiliesExWis defined as follows (SDK 10.0.18362.0):In practice, the differing argument types are representation-compatible anyway, so it works fine, but it does require a cast on the function pointer. It was suggested in #871 to get this sorted out.
Affected files:
BTW,
src/renderer/gdi/tool/main.cppis not included in any project in the solution, preventing it to be scanned by an IDE. Is that intentional?