terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
ListenerAsyncResult.cs
Go to the documentation of this file.
1using System;
2using System.IO;
4
5namespace System.Net
6{
7 // Token: 0x02000261 RID: 609
9 {
10 // Token: 0x06001062 RID: 4194 RVA: 0x00033BC8 File Offset: 0x00031DC8
12 {
13 }
14
15 // Token: 0x06001063 RID: 4195 RVA: 0x00033BE4 File Offset: 0x00031DE4
16 internal void Complete(Exception exc)
17 {
19 if (listenerAsyncResult != null)
20 {
22 return;
23 }
24 bool inGet = this.InGet;
25 this.exception = exc;
26 int num;
27 if (inGet && exc != null)
28 {
29 num = 500;
30 }
31 object obj = this.locker;
32 Monitor.Enter(obj, num != 0);
34 int num2 = 1;
35 this.completed = num2 != 0;
36 if (manualResetEvent != null)
37 {
38 bool flag = manualResetEvent.Set();
39 }
41 if (asyncCallback != null)
42 {
43 if (asyncCallback == null)
44 {
45 }
46 return;
47 }
48 long num3 = 0L;
49 if (asyncCallback != null)
50 {
52 }
53 if (num3 == 0L)
54 {
55 return;
56 }
57 throw new OutOfMemoryException();
58 }
59
60 // Token: 0x06001064 RID: 4196 RVA: 0x00033C98 File Offset: 0x00031E98
61 private static void InvokeCallback(object o)
62 {
63 if (o != null)
64 {
65 }
66 }
67
68 // Token: 0x06001065 RID: 4197 RVA: 0x00033CB4 File Offset: 0x00031EB4
70 {
71 long num = 0L;
72 this.Complete(context, num != 0L);
73 }
74
75 // Token: 0x06001066 RID: 4198 RVA: 0x00033CCC File Offset: 0x00031ECC
77 {
78 int num = 1;
80 if (listenerAsyncResult != null)
81 {
83 return;
84 }
85 object obj = this.locker;
86 this.synch = num != 0;
90 if (context.request.headers["Authorization"] == null)
91 {
93 int num2 = 401;
96 string realm = context.Listener.realm;
97 string text2;
98 string text = text2 + " realm=\"" + realm + "\"";
99 headers["WWW-Authenticate"] = text;
101 HttpListener listener = context.Listener;
102 Monitor.Enter(headers, true);
103 return;
104 }
106 int num3 = 256;
107 this.synch = num3 != 0;
108 if (manualResetEvent != null)
109 {
110 bool flag = manualResetEvent.Set();
111 }
113 if (asyncCallback != null)
114 {
115 if (asyncCallback == null)
116 {
117 }
118 return;
119 }
120 long num4 = 0L;
122 if (num4 == 0L)
123 {
124 return;
125 }
126 throw new OutOfMemoryException();
127 }
128
129 // Token: 0x06001067 RID: 4199 RVA: 0x00033E60 File Offset: 0x00032060
131 {
132 while (this.forward != null || this.exception != null)
133 {
134 }
135 return this.context;
136 }
137
138 // Token: 0x170003A8 RID: 936
139 // (get) Token: 0x06001068 RID: 4200 RVA: 0x00033E84 File Offset: 0x00032084
140 public object AsyncState
141 {
142 get
143 {
144 while (this.forward != null)
145 {
146 }
147 return this.state;
148 }
149 }
150
151 // Token: 0x170003A9 RID: 937
152 // (get) Token: 0x06001069 RID: 4201 RVA: 0x00033EA0 File Offset: 0x000320A0
154 {
155 get
156 {
158 if (listenerAsyncResult != null)
159 {
161 }
162 object obj = this.locker;
163 if (this.handle != null)
164 {
165 }
166 bool flag = this.completed;
167 long num = 0L;
169 if (num == 0L)
170 {
172 }
173 throw new OutOfMemoryException();
174 }
175 }
176
177 // Token: 0x170003AA RID: 938
178 // (get) Token: 0x0600106A RID: 4202 RVA: 0x00033F08 File Offset: 0x00032108
180 {
181 get
182 {
183 while (this.forward != null)
184 {
185 }
186 return this.synch;
187 }
188 }
189
190 // Token: 0x170003AB RID: 939
191 // (get) Token: 0x0600106B RID: 4203 RVA: 0x00033F24 File Offset: 0x00032124
192 public bool IsCompleted
193 {
194 get
195 {
197 bool isCompleted;
198 if (listenerAsyncResult != null)
199 {
200 isCompleted = listenerAsyncResult.IsCompleted;
201 return isCompleted;
202 }
203 long num = 0L;
204 Monitor.Exit(isCompleted);
205 if (num == 0L)
206 {
207 return isCompleted;
208 }
209 throw new OutOfMemoryException();
210 }
211 }
212
213 // Token: 0x0600106C RID: 4204 RVA: 0x00033F74 File Offset: 0x00032174
214 // Note: this type is marked as 'beforefieldinit'.
216 {
217 }
218
219 // Token: 0x04000CE2 RID: 3298
221
222 // Token: 0x04000CE3 RID: 3299
223 private bool synch;
224
225 // Token: 0x04000CE4 RID: 3300
226 private bool completed;
227
228 // Token: 0x04000CE5 RID: 3301
229 private AsyncCallback cb = cb;
230
231 // Token: 0x04000CE6 RID: 3302
232 private object state = state;
233
234 // Token: 0x04000CE7 RID: 3303
236
237 // Token: 0x04000CE8 RID: 3304
239
240 // Token: 0x04000CE9 RID: 3305
241 private object locker;
242
243 // Token: 0x04000CEA RID: 3306
245
246 // Token: 0x04000CEB RID: 3307
247 internal bool EndCalled;
248
249 // Token: 0x04000CEC RID: 3308
250 internal bool InGet;
251
252 // Token: 0x04000CED RID: 3309
253 private static WaitCallback InvokeCB;
254 }
255}
class f__AnonymousType0<< Count > j__TPar
AuthenticationSchemes auth_schemes
AuthenticationSchemes SelectAuthenticationScheme(HttpListenerContext context)
ListenerAsyncResult(AsyncCallback cb, object state)
void Complete(HttpListenerContext context)
static void InvokeCallback(object o)
void Complete(HttpListenerContext context, bool synch)
static void Exit(object obj)
Definition Monitor.cs:47
static void Enter(object obj)
Definition Monitor.cs:11