File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
src/Servers/Kestrel/Core/src/Internal/Infrastructure Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ private static ulong GetMaskAsLong(ReadOnlySpan<byte> bytes)
80
80
return BinaryPrimitives . ReadUInt64LittleEndian ( bytes ) ;
81
81
}
82
82
83
- // The same as GetAsciiStringNonNullCharacters but throws BadRequest
83
+ // The same as GetAsciiString but throws BadRequest for null character
84
84
[ MethodImpl ( MethodImplOptions . AggressiveInlining ) ]
85
85
public static string GetHeaderName ( this ReadOnlySpan < byte > span )
86
86
{
@@ -107,6 +107,7 @@ public static string GetHeaderName(this ReadOnlySpan<byte> span)
107
107
public static string GetAsciiString ( this Span < byte > span )
108
108
=> StringUtilities . GetAsciiString ( span ) ;
109
109
110
+ // Null checks must be done independently of this method (if required)
110
111
public static string GetAsciiOrUTF8String ( this ReadOnlySpan < byte > span )
111
112
=> StringUtilities . GetAsciiOrUTF8String ( span , DefaultRequestHeaderEncoding ) ;
112
113
You can’t perform that action at this time.
0 commit comments