Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
SyncRequestContext.cs
Go to the documentation of this file.
1namespace System.Net;
2
4{
5 internal unsafe SyncRequestContext(int size)
6 {
8 }
9
10 private unsafe global::Interop.HttpApi.HTTP_REQUEST* Allocate(int newSize)
11 {
12 if (base.Size != 0 && base.Size == newSize)
13 {
14 return base.RequestBlob;
15 }
17 if (!(base.RequestBuffer == IntPtr.Zero))
18 {
19 return (global::Interop.HttpApi.HTTP_REQUEST*)base.RequestBuffer.ToPointer();
20 }
21 return null;
22 }
23
24 internal unsafe void Reset(int size)
25 {
26 SetBlob(Allocate(size));
27 }
28
29 protected override void OnReleasePins()
30 {
31 }
32}
unsafe void SetBuffer(int size)
unsafe void BaseConstruction(global::Interop.HttpApi.HTTP_REQUEST *requestBlob)
unsafe void SetBlob(global::Interop.HttpApi.HTTP_REQUEST *requestBlob)
unsafe global::Interop.HttpApi.HTTP_REQUEST * Allocate(int newSize)
static readonly IntPtr Zero
Definition IntPtr.cs:18