-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Restrict indentation size in JsonWriterOptions theories. #101498
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7637,7 +7637,7 @@ private static IEnumerable<JsonWriterOptions> JsonOptions() | |
return from indented in new[] { true, false } | ||
from skipValidation in new[] { true, false } | ||
from indentCharacter in indented ? new char?[] { null, ' ', '\t' } : [] | ||
from indentSize in indented ? new int?[] { null, 0, 1, 2, 127 } : [] | ||
from indentSize in indented ? new int?[] { null, 0, 1, 2, 3 } : [] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why would the indent size result in OOMs? Significantly larger buffer sizes? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Correct. The impacted test creates very deep objects so a large indent size would contribute to substantially bigger buffer sizes. |
||
from newLine in indented ? new string?[] { null, "\n", "\r\n" } : [] | ||
select CreateOptions(indented, indentCharacter, indentSize, skipValidation, newLine); | ||
|
||
|
Uh oh!
There was an error while loading. Please reload this page.