Skip to content

Commit f396f74

Browse files
committed
mtest.h: update to v1.4.2
Signed-off-by: Michał Łyszczek <michal.lyszczek@bofc.pl>
1 parent ae840ef commit f396f74

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

mtest.h

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Author: Michał Łyszczek <michal.lyszczek@bofc.pl>
44
==========================================================================
55
__________________________________________________________
6-
/ mtest v1.4.1 \
6+
/ mtest v1.4.2 \
77
| https://mtest.bofc.pl |
88
| |
99
| Simple test framework that uses TAP output format |
@@ -28,6 +28,7 @@
2828

2929

3030
#include <stdio.h>
31+
#include <stdatomic.h>
3132

3233

3334
/* ==========================================================================
@@ -46,11 +47,11 @@
4647

4748
#define mt_defs() \
4849
const char *curr_test; \
49-
int mt_test_status; \
50-
int mt_total_tests = 0; \
51-
int mt_total_failed = 0; \
52-
int mt_total_checks = 0; \
53-
int mt_checks_failed = 0; \
50+
atomic_int mt_test_status; \
51+
atomic_int mt_total_tests = 0; \
52+
atomic_int mt_total_failed = 0; \
53+
atomic_int mt_total_checks = 0; \
54+
atomic_int mt_checks_failed = 0; \
5455
static void (*mt_prepare_test)(void); \
5556
static void (*mt_cleanup_test)(void)
5657

@@ -64,11 +65,11 @@
6465

6566
#define mt_defs_ext()\
6667
extern const char *curr_test; \
67-
extern int mt_test_status; \
68-
extern int mt_total_tests; \
69-
extern int mt_total_failed; \
70-
extern int mt_total_checks; \
71-
extern int mt_checks_failed; \
68+
extern atomic_int mt_test_status; \
69+
extern atomic_int mt_total_tests; \
70+
extern atomic_int mt_total_failed; \
71+
extern atomic_int mt_total_checks; \
72+
extern atomic_int mt_checks_failed; \
7273
static void (*mt_prepare_test)(void); \
7374
static void (*mt_cleanup_test)(void)
7475

0 commit comments

Comments
 (0)