Skip to content

Commit 3c3d67c

Browse files
lvJianWuniemyjski
authored andcommitted
Update RequestInfoCollector.cs (#200)
fix bug,When Post data is less than 1024, it does not display problems.
1 parent 9a814ad commit 3c3d67c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Platforms/Exceptionless.AspNetCore/RequestInfoCollector.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ private static object GetPostData(HttpContext context, ExceptionlessConfiguratio
105105
int bufferSize = (int)Math.Min(1024, maxDataToRead);
106106

107107
char[] buffer = new char[bufferSize];
108-
while ((numRead = inputStream.ReadBlock(buffer, 0, bufferSize)) > 0 && (sb.Length + numRead) < maxDataToRead) {
108+
while ((numRead = inputStream.ReadBlock(buffer, 0, bufferSize)) > 0 && (sb.Length + numRead) <= maxDataToRead) {
109109
sb.Append(buffer, 0, numRead);
110110
}
111111
string postData = sb.ToString();
@@ -186,4 +186,4 @@ private static string GetClientIpAddress(this HttpContext context) {
186186
return context.Connection.RemoteIpAddress?.ToString();
187187
}
188188
}
189-
}
189+
}

0 commit comments

Comments
 (0)