File tree 2 files changed +4
-4
lines changed
Fuzzing/DotnetFuzzing/Fuzzers
System.Text.Json/src/System/Text/Json/Writer
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -119,7 +119,7 @@ public void FuzzTarget(ReadOnlySpan<byte> bytes)
119
119
}
120
120
121
121
// Additional test for mixing UTF-8 and UTF-16 encoding. The alignment math is easier in UTF-16 mode so just run it for that.
122
- if ( encoding == Utf16EncodingFlag )
122
+ if ( encoding == Utf16EncodingFlag && ! options . SkipValidation )
123
123
{
124
124
Array . Clear ( expectedBuffer ) ;
125
125
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ public sealed partial class Utf8JsonWriter
18
18
/// Thrown when the specified value is too large.
19
19
/// </exception>
20
20
/// <exception cref="InvalidOperationException">
21
- /// Thrown if this would result in invalid JSON being written (while validation is enabled) or
21
+ /// Thrown when validation is enabled if this would result in invalid JSON being written or
22
22
/// if the previously written segment (if any) was not written with this same overload.
23
23
/// </exception>
24
24
/// <remarks>
@@ -186,7 +186,7 @@ private void WriteStringSegmentData(ReadOnlySpan<char> escapedValue)
186
186
/// Thrown when the specified value is too large.
187
187
/// </exception>
188
188
/// <exception cref="InvalidOperationException">
189
- /// Thrown if this would result in invalid JSON being written (while validation is enabled) or
189
+ /// Thrown when validation is enabled if this would result in invalid JSON being written or
190
190
/// if the previously written segment (if any) was not written with this same overload.
191
191
/// </exception>
192
192
/// <remarks>
@@ -353,7 +353,7 @@ private void WriteStringSegmentData(ReadOnlySpan<byte> escapedValue)
353
353
/// Thrown when the specified value is too large.
354
354
/// </exception>
355
355
/// <exception cref="InvalidOperationException">
356
- /// Thrown if this would result in invalid JSON being written (while validation is enabled) or
356
+ /// Thrown when validation is enabled if this would result in invalid JSON being written or
357
357
/// if the previously written segment (if any) was not written with this same overload.
358
358
/// </exception>
359
359
public void WriteBase64StringSegment ( ReadOnlySpan < byte > value , bool isFinalSegment )
You can’t perform that action at this time.
0 commit comments