public static void smethod_5() { Class65.Class68 stateMachine = new Class65.Class68(); stateMachine.asyncVoidMethodBuilder_0 = AsyncVoidMethodBuilder.Create(); stateMachine.int_0 = -1; stateMachine.asyncVoidMethodBuilder_0.Start <Class65.Class68>(ref stateMachine); }
unsafe void IAsyncStateMachine.MoveNext() { // ISSUE: untyped stack allocation void *voidPtr = (void *)__untypedstackalloc(5); int int0 = this.int_0; try { TaskAwaiter awaiter; int num; if (int0 == 0) { awaiter = this.taskAwaiter_0; this.taskAwaiter_0 = new TaskAwaiter(); num = -1; this.int_0 = -1; } else { goto label_5; } label_3: awaiter.GetResult(); awaiter = new TaskAwaiter(); label_4: this.object_0 = (object)null; label_5: *(sbyte *)((IntPtr)voidPtr + 4) = (sbyte)(Class65.sqlConnection_0.State != ConnectionState.Open); if (*(sbyte *)((IntPtr)voidPtr + 4) != (sbyte)0) { this.int_1 = 0; try { Class65.sqlConnection_0.Open(); } catch (object ex) { this.object_0 = ex; this.int_1 = 1; } *(int *)voidPtr = this.int_1; if (*(int *)voidPtr == 1) { Form1.smethod_0("SQL bağlantı koptu. Yeniden bağlantı deneneniyor."); awaiter = Task.Delay(2).GetAwaiter(); if (!awaiter.IsCompleted) { num = 0; this.int_0 = 0; this.taskAwaiter_0 = awaiter; Class65.Class68 stateMachine = this; this.asyncVoidMethodBuilder_0.AwaitUnsafeOnCompleted <TaskAwaiter, Class65.Class68>(ref awaiter, ref stateMachine); return; } goto label_3; } else { goto label_4; } } } catch (Exception ex) { this.int_0 = -2; this.asyncVoidMethodBuilder_0.SetException(ex); return; } this.int_0 = -2; this.asyncVoidMethodBuilder_0.SetResult(); }