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 exception when writing resx files without adding any resources #3418

Merged
merged 1 commit into from
Mar 8, 2025

Conversation

jwfx
Copy link
Contributor

@jwfx jwfx commented Mar 4, 2025

Problem

Version 9.0.0.7889 throws a NullReferenceException when trying to write a resx file without calling AddResource() due to the uninitialized writer.

Solution

Initialize the writer during Generate, in case it was not initialized yet.

@siegfriedpammer siegfriedpammer merged commit bada92e into icsharpcode:master Mar 8, 2025
5 checks passed
@siegfriedpammer
Copy link
Member

Thank you very much!

@jwfx
Copy link
Contributor Author

jwfx commented Mar 8, 2025

Thank you very much!

Thanks for the quick reaction time on review and merge, much appreciated. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants