ReactOS 0.4.16-dev-334-g4d9f67c
seh0001.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[] = "SEH0001.c";
9
10int main() {
11 long Counter;
12
13 Counter = 0;
14
15 try {
16 Counter += 1;
17 }
18 finally {
19 if (abnormal_termination() == 0) {
20 Counter += 1;
21 }
22 }
23 endtry
24
25 if (Counter != 2) {
26 printf("TEST 1 FAILED. Counter = %d\n\r", Counter);
27 return -1;
28 }
29 return 0;
30}
#define printf
Definition: freeldr.h:97
char test[]
Definition: seh0001.c:8
int main()
Definition: seh0001.c:10
#define endtry
Definition: seh.h:24
#define abnormal_termination
Definition: seh.h:25
static LARGE_INTEGER Counter
Definition: clock.c:43