ReactOS 0.4.15-dev-7906-g1b85a5f
seh0053.c
Go to the documentation of this file.
1// Copyright (c) Microsoft. All rights reserved.
2// Licensed under the MIT license. See LICENSE file in the project root for
3// full license information.
4
5#include <windows.h>
6#include "seh.h"
7
8char test[] = "seh0053.c";
9
10#define BLUE 0
11#define RED 1
12
13int main() {
15 ULONG Index2 = RED;
16
17 Counter = 0;
18
19 try {
20 switch (Index2) {
21 case BLUE:
22 break;
23
24 case RED:
25 Counter += 3;
26 leave;
27 }
28
29 Counter += 100;
30 }
31 finally {
32 if (abnormal_termination() == FALSE) {
33 Counter += 5;
34 }
35 }
36 endtry
37
38 if (Counter != 8) {
39 printf("TEST 53 FAILED, Counter = %d\n", Counter);
40 return -1;
41 }
42
43 return 0;
44}
#define leave
Definition: btrfs_drv.h:138
#define FALSE
Definition: types.h:117
#define printf
Definition: freeldr.h:93
long LONG
Definition: pedump.c:60
#define BLUE
Definition: seh0053.c:10
#define RED
Definition: seh0053.c:11
char test[]
Definition: seh0053.c:8
int main()
Definition: seh0053.c:13
#define endtry
Definition: seh.h:24
#define abnormal_termination
Definition: seh.h:25
static LARGE_INTEGER Counter
Definition: clock.c:43
uint32_t ULONG
Definition: typedefs.h:59