Skip to content

Conversation

@AndreaMarangoni
Copy link
Contributor

Fixes #7923

From this #7923 (comment) I implemented solution 1, switching from main to wmain, as the quickest and cleanest to implement.

@AndreaMarangoni AndreaMarangoni marked this pull request as ready for review December 31, 2024 13:08
@AndreaMarangoni AndreaMarangoni requested review from a team as code owners December 31, 2024 13:08
@zwass
Copy link
Member

zwass commented Jan 2, 2025

These changes make sense to me, but when I tried testing on my Windows VM it still crashed with the ä character as in the bug report.

Did it work for you @AndreaMarangoni? If so, I will try doing it again to see if I may have made a mistake in my testing.

@AndreaMarangoni
Copy link
Contributor Author

These changes make sense to me, but when I tried testing on my Windows VM it still crashed with the ä character as in the bug report.

Did it work for you @AndreaMarangoni? If so, I will try doing it again to see if I may have made a mistake in my testing.

No you were right. The linkage to wmain was actually broken and it was calling main still. My testing was right, but then realised I was linking wmain everywhere. So I reduced the scope of /ENTRY:wmain... to only osqueryd target before re-testing, without realising the linkage was actually broken. Maybe a good idea would have been to rename the main function to something else.
Thank you for testing it!
Now it should work fine.

@michael-myers michael-myers added ready for review Pull requests that are ready to be reviewed by a maintainer Windows labels Jan 3, 2025
Copy link
Member

@zwass zwass left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's working for me now, thanks!

@zwass zwass merged commit 907f0e4 into osquery:master Feb 5, 2025
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready for review Pull requests that are ready to be reviewed by a maintainer Windows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OsQuery crashing on Windows when using non-ascii characters in path

3 participants